-
Notifications
You must be signed in to change notification settings - Fork 194
feat: ease webpack configuration and add support Node ESM #867
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
Conversation
Previously, maxGraph integration in a webpack build required the addition of a specific configuration. Imports into maxGraph code did not include the “js” extension required by webpack for import resolution. A workaround was needed in the configuration, otherwise an error would occur. For the same reason, Node.js emitted an error when importing maxGraph into ESM scripts or applications. No workaround was available. All imports into maxGraph ESM code provided in the npm package now include the “js” extension, which corrects both past problems. A new eslint plugin has been added to reinforce the “js” extension. It provides an automatic correction for the corresponding rule. The webpack and Node ESM examples in this repository have been updated to demonstrate the new behavior.
Important Review skippedMore than 25% of the files skipped due to max files limit. The review is being skipped to prevent a low-quality review. 161 files out of 268 files are above the max files limit of 100. Please upgrade to Pro plan to get higher limits. You can disable this status message by setting the ✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
Previously, maxGraph integration in a webpack build required the addition of a specific configuration.
Imports into maxGraph code did not include the “js” extension required by webpack for import resolution. A workaround was needed in the configuration, otherwise an error would occur.
For the same reason, Node.js emitted an error when importing maxGraph into ESM scripts or applications. No workaround was available.
All imports into maxGraph ESM code provided in the npm package now include the “js” extension, which corrects both past problems.
A new eslint plugin has been added to reinforce the “js” extension. It provides an automatic correction for the corresponding rule.
The webpack and Node ESM examples in this repository have been updated to demonstrate the new behavior.
Notes
Closes #827