Skip to content

Commit

Permalink
Use @handlebars/parser v2
Browse files Browse the repository at this point in the history
We have to remove `--failAfterWarnings` from our Rollup integration-test,
because Typescript, when targeting es5, will use global `this` for transpilation.
Rollup warns about this, since it replaces `this` with `undefined`:

```
src/index.js → dist/bundle.js...
(!) `this` has been rewritten to `undefined`
https://rollupjs.org/guide/en/#error-this-is-undefined
../../../node_modules/@handlebars/parser/dist/esm/printer.js
1: var __spreadArrays = (this && this.__spreadArrays) || function () {}
```

See https://github.com/handlebars-lang/handlebars-parser/releases/tag/v2.0.0
  • Loading branch information
jaylinski committed Oct 29, 2022
1 parent 262b84b commit e668696
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
14 changes: 7 additions & 7 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"node": ">=12"
},
"dependencies": {
"@handlebars/parser": "^1.1.0",
"@handlebars/parser": "^2.1.0",
"neo-async": "^2.6.2",
"source-map": "^0.6.1",
"yargs": "^16.2.0"
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/rollup-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"description": "Various tests with Handlebars and rollup",
"version": "1.0.0",
"scripts": {
"build": "rollup --config rollup.config.js --failAfterWarnings"
"build": "rollup --config rollup.config.js"
},
"private": true,
"devDependencies": {
Expand Down

0 comments on commit e668696

Please sign in to comment.