Make @zwave-js/config paths "bundle friendly" #6556
Closed
robertsLando
started this conversation in
Feature Requests
Replies: 1 comment 1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Description
When playing with esbuild on zui I had to do some monkey patch on final bundle in order to make it work. To prevent this we could make the paths more bundle friendly using
require.resolve
Do you have a solution in mind?
Store somewhere in a const
const baseDir = dirname(require.resolve('@zwave-js/config/package.json'))
and use that as base inconfigDir
andgetEmbeddedConfigVersion
paths. Notice this will work only when zwave-js is used inside a moduleDescribe alternatives you've considered
keep using the monkey patch
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions