Skip to content

Commit

Permalink
chore(workspace): reduce complexity of jest setup (#649)
Browse files Browse the repository at this point in the history
#### What this PR does / why we need it:

As per title.
  • Loading branch information
fuxingloh authored Oct 20, 2023
1 parent ab73bb2 commit cfc31fa
Show file tree
Hide file tree
Showing 28 changed files with 409 additions and 981 deletions.
3 changes: 0 additions & 3 deletions .npmrc

This file was deleted.

6 changes: 6 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,14 @@
"*": "prettier --write --ignore-unknown"
},
"devDependencies": {
"@jest/globals": "^29.7.0",
"@types/node": "^18.18.6",
"@typescript-eslint/eslint-plugin": "^6.7.0",
"@typescript-eslint/parser": "^6.7.0",
"@workspace/jest-preset": "workspace:*",
"@workspace/tsconfig": "workspace:*",
"esbuild": "^0.19.4",
"esbuild-jest": "^0.5.0",
"eslint": "^8.49.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-config-airbnb-typescript": "^17.1.0",
Expand All @@ -34,10 +38,12 @@
"eslint-plugin-simple-import-sort": "^10.0.0",
"eslint-plugin-unused-imports": "^3.0.0",
"husky": "^8.0.3",
"jest": "29.7.0",
"lint-staged": "^14.0.1",
"prettier": "^3.0.3",
"prettier-plugin-packagejson": "^2.4.5",
"prettier-plugin-tailwindcss": "^0.4.1",
"ts-jest": "29.1.1",
"turbo": "^1.10.16",
"typescript": "5.2.2"
},
Expand Down

This file was deleted.

19 changes: 0 additions & 19 deletions packages/contented-example/contented-example-lorem/package.json

This file was deleted.

15 changes: 2 additions & 13 deletions packages/contented-example/contented.config.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { MarkdownPipeline } from '@contentedjs/contented-pipeline-md';
import { JestMarkdownPipeline } from '@contentedjs/contented-pipeline-jest-md';

/** @type {import('@contentedjs/contented').ContentedConfig} */
const config = {
Expand Down Expand Up @@ -63,20 +62,10 @@ const config = {
{
type: 'Lorem',
dir: 'packages/contented-example',
pattern: ['contented-example-lorem/**/*.md'],
pattern: ['lorem/**/*.md'],
processor: MarkdownPipeline,
transform: (file) => {
file.path = file.path.replaceAll(/^\/contented-example-lorem\/?/g, '/');
file.sections = file.sections.slice(1);
return file;
},
},
{
type: 'Contented',
dir: 'packages/contented-example',
pattern: 'jest/**/*.md.[tj]s',
processor: JestMarkdownPipeline,
transform: (file) => {
file.path = file.path.replaceAll(/^\/lorem\/?/g, '/');
file.sections = file.sections.slice(1);
return file;
},
Expand Down
76 changes: 0 additions & 76 deletions packages/contented-example/jest/Pipelines/100-JestMarkdown.md.ts

This file was deleted.

18 changes: 0 additions & 18 deletions packages/contented-example/jest/Pipelines/200-JestMarkdownJs.md.js

This file was deleted.

31 changes: 0 additions & 31 deletions packages/contented-example/jest/package.json

This file was deleted.

6 changes: 0 additions & 6 deletions packages/contented-example/jest/tsconfig.json

This file was deleted.

1 change: 0 additions & 1 deletion packages/contented-example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
},
"devDependencies": {
"@contentedjs/contented": "workspace:*",
"@contentedjs/contented-pipeline-jest-md": "workspace:*",
"@contentedjs/contented-pipeline-md": "workspace:*"
}
}
49 changes: 0 additions & 49 deletions packages/contented-pipeline-jest-md/package.json

This file was deleted.

85 changes: 0 additions & 85 deletions packages/contented-pipeline-jest-md/src/JestMarkdownPipeline.ts

This file was deleted.

Loading

0 comments on commit cfc31fa

Please sign in to comment.