Skip to content

Commit

Permalink
Merge pull request #4145 from alphagov/update-mangling-option
Browse files Browse the repository at this point in the history
  • Loading branch information
romaricpascal authored Aug 31, 2023
2 parents 03cd9bb + c1af8e1 commit 8f0013a
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion rollup.release.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,13 @@ export default defineConfig(({ i: input }) => ({
plugins: [
terser({
format: { comments: false },
mangle: { reserved: Object.keys(GOVUKFrontend) },
mangle: {
keep_classnames: true,
keep_fnames: true,
// Ensure all top-level exports skip mangling, for example
// non-function string constants like `export { version }`
reserved: Object.keys(GOVUKFrontend)
},

// Include sources content from source maps to inspect
// GOV.UK Frontend and other dependencies' source code
Expand Down

0 comments on commit 8f0013a

Please sign in to comment.