Skip to content

Commit

Permalink
Don't mangle ScrollTimeline and ViewTimeline class names to satisfy w…
Browse files Browse the repository at this point in the history
…pt. (flackr#225)
  • Loading branch information
flackr authored Feb 4, 2024
1 parent d605aba commit 8b52a5c
Show file tree
Hide file tree
Showing 4 changed files with 224 additions and 4 deletions.
215 changes: 215 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
},
"homepage": "https://github.com/flackr/scroll-timeline#readme",
"devDependencies": {
"terser": "^5.27.0",
"vite": "^5.0.12"
}
}
4 changes: 2 additions & 2 deletions test/expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@ PASS /scroll-animations/scroll-timelines/idlharness.window.html Element includes
PASS /scroll-animations/scroll-timelines/idlharness.window.html Element includes Slottable: member names are unique
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface: existence and properties of interface object
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface object length
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface object name
PASS /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface object name
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface: existence and properties of interface prototype object
PASS /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface: existence and properties of interface prototype object's "constructor" property
PASS /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface: existence and properties of interface prototype object's @@unscopables property
Expand All @@ -805,7 +805,7 @@ PASS /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline i
PASS /scroll-animations/scroll-timelines/idlharness.window.html ScrollTimeline interface: new ScrollTimeline() must inherit property "axis" with the proper type
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface: existence and properties of interface object
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface object length
FAIL /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface object name
PASS /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface object name
PASS /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface: existence and properties of interface prototype object
PASS /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface: existence and properties of interface prototype object's "constructor" property
PASS /scroll-animations/scroll-timelines/idlharness.window.html ViewTimeline interface: existence and properties of interface prototype object's @@unscopables property
Expand Down
8 changes: 6 additions & 2 deletions vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ export default defineConfig({
name: 'ScrollTimeline',
// the proper extensions will be added
fileName: (format, entryAlias) => `scroll-timeline${format=='iife'?'':'-' + format}.js`,
formats: ['iife']
formats: ['iife'],
},
minify: 'terser',
terserOptions: {
keep_classnames: /^((View|Scroll)Timeline)|CSS.*$/
},
rollupOptions: {
output: {
Expand All @@ -19,6 +23,6 @@ export default defineConfig({
globals: {
},
},
},
}
},
})

0 comments on commit 8b52a5c

Please sign in to comment.