Skip to content

Commit

Permalink
build(deps): update acorn to 8.7
Browse files Browse the repository at this point in the history
  • Loading branch information
Ffloriel committed Feb 27, 2022
1 parent 726faaa commit 1ae4a5e
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 131 deletions.
170 changes: 44 additions & 126 deletions package-lock.json

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

5 changes: 4 additions & 1 deletion packages/purgecss-from-jsx/__tests__/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ import purgeJsx from "../src/index";

import { TEST_1_CONTENT, TEST_1_TAG, TEST_1_CLASS, TEST_1_ID } from "./data";

const plugin = purgeJsx({ sourceType: "module" });
const plugin = purgeJsx({
ecmaVersion: 'latest',
sourceType: "module"
});

describe("purgePug", () => {
describe("from a normal html document", () => {
Expand Down
4 changes: 2 additions & 2 deletions packages/purgecss-from-jsx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@
"url": "https://github.com/FullHuman/purgecss/issues"
},
"dependencies": {
"acorn": "^7.4.0",
"acorn": "^8.7.0",
"acorn-jsx": "^5.3.1",
"acorn-jsx-walk": "^2.0.0",
"acorn-walk": "^8.1.1"
"acorn-walk": "^8.2.0"
},
"publishConfig": {
"access": "public",
Expand Down
2 changes: 1 addition & 1 deletion packages/purgecss-from-jsx/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function purgeFromJsx(options?: acorn.Options) {
walk.recursive<NodeState>(
acorn.Parser.extend(
jsx() as (BaseParser: typeof acorn.Parser) => typeof acorn.Parser
).parse(content, options),
).parse(content, options || { ecmaVersion: "latest" }),
state,
{
JSXOpeningElement(acornNode, state, callback) {
Expand Down
2 changes: 1 addition & 1 deletion packages/purgecss-from-tsx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
},
"dependencies": {
"@fullhuman/purgecss-from-jsx": "^4.1.0",
"acorn": "^7.4.0",
"acorn": "^8.7.0",
"typescript": "^4.5.3"
},
"publishConfig": {
Expand Down

0 comments on commit 1ae4a5e

Please sign in to comment.