-
Notifications
You must be signed in to change notification settings - Fork 16
Check Intl config for inputPath #95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Check Intl config for inputPath #95
Conversation
|
out of curiosity, why are you using a different path? |
|
We use bit to share and edit files between projects, store them (including our translations) under a subdirectory. This lets our front-end team make changes to our translation files during development, and keep those changes in sync for our back-end team without having to manage multiple npm repositories/releases. In either case, given that this option is available to intl users, its a good idea to support it in the analyzer? |
|
|
||
| let config; | ||
| if (fs.existsSync(configPath)) { | ||
| let requireESM = require('esm')(module); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the default ember-intl blueprint is using module.exports (not export default), so I'm not sure why we would need to support ES module files here.
also, I would assume that the default export would still be a function, but it seems that the code below does not call the default and assumes that it is an object directly, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have ember-intl changed their setup recently because this PR worked when I opened it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure. I've checked in a few of my projects that use ember-intl and they all use module.exports 😅
Checks for
inputPathoption inconfig/ember-intl.js.I've also pulled in the change from #94 as I couldn't run the code without it.