lost
lost copied to clipboard
🔧 Fixes params splitting issues for other rules
What kind of change is this? (Bug Fix, Feature...) Fix
What is the current behavior (You can also link to an issue) It's breaking params for the rules that are not related to lost, and I'm using a @font-face rule which doesn't having any rule params therefore resulting in a TypeError: Cannot read properties of undefined (reading 'split')
What is the new behavior this introduces (if any) It now check the rule name first before breaking the params to avoid this error and successfully builds
Does this introduce any breaking changes? No, they're not breaking changes
Does the PR fulfill these requirements?
- [x] Tests for the changes have been added
- [ ] Docs have been added or updated
Other Comments
Codecov Report
Merging #456 (82d6a7d) into master (a47413c) will not change coverage. The diff coverage is
100.00%
.
@@ Coverage Diff @@
## master #456 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 20 20
Lines 776 776
=========================================
Hits 776 776
Impacted Files | Coverage Δ | |
---|---|---|
lib/lost-at-rule.js | 100.00% <100.00%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update a47413c...82d6a7d. Read the comment docs.
I'm poking around writing a test for this and struggling to get it to fail. I'm sure I'm just missing something. Could you share what you're working on?
...that said, reading the code your change does make sense and should be merged. Now I'm just trying to get a failing test so we don't get a regression.