-
Notifications
You must be signed in to change notification settings - Fork 15
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
fix: className conflict to keyword like constuctor or toString #1
fix: className conflict to keyword like constuctor or toString #1
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1 +/- ##
=======================================
Coverage ? 100%
=======================================
Files ? 1
Lines ? 103
Branches ? 24
=======================================
Hits ? 103
Misses ? 0
Partials ? 0
Continue to review full report at Codecov.
|
@evilebottnawi can you release a patch version? |
@jerry-i hm, how we can test this? |
@evilebottnawi I have add one test case for it. And you can see the erorr case online. |
@jerry-i thanks will be released in patch version in near future |
src/index.js
Outdated
@@ -58,7 +58,8 @@ const processor = postcss.plugin('postcss-modules-scope', function(options) { | |||
const generateScopedName = | |||
(options && options.generateScopedName) || processor.generateScopedName; | |||
|
|||
const exports = {}; | |||
let exports = Object.create(null); | |||
// let exports = {}; |
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.
Remove comment, and why don't use const
?
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.
done!
Third part lib like
monaco-editor
has the css selector name like .constructor which conflict withObject
's keywords.😂