web: optimize tests by ~120% (#1018)

This is mainly done via sharding, caching & reducing total work:
1. `terser` is turned off when generating test build
2. `nx` distributed cache allows reusing build outputs
3. `playwright` sharding allows running tests in parallel

This can further be improved by using `swc` & `esbuild` during build
This commit is contained in:
Abdullah Atta
2022-09-21 14:01:32 +05:00
committed by GitHub
parent e347922be9
commit 6d75476e7c
14 changed files with 310 additions and 97 deletions

View File

@@ -22,20 +22,33 @@ jobs:
steps:
- uses: actions/checkout@v3
- name: Use Node.js 16.x
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 16.x
cache: 'npm'
cache-dependency-path: '**/package-lock.json'
cache: "npm"
cache-dependency-path: |
apps/mobile/package-lock.json
apps/web/package-lock.json
packages/core/package-lock.json
packages/crypto/package-lock.json
packages/crypto-worker/package-lock.json
packages/editor-mobile/package-lock.json
packages/editor/package-lock.json
packages/logger/package-lock.json
packages/streamable-fs/package-lock.json
packages/theme/package-lock.json
- name: Prepare environment
run: |
npm ci
npm ci --no-audit
- name: Add environment variables
run: |
echo "EMAIL=${{ secrets.USER_EMAIL }}" >> $GITHUB_ENV
echo "PASSWORD='${{ secrets.USER_PASSWORD }}'" >> $GITHUB_ENV
echo "HASHED_PASSWORD=${{ secrets.USER_HASHED_PASSWORD }}" >> $GITHUB_ENV
echo "NX_CLOUD_ACCESS_TOKEN=${{ secrets.NX_CLOUD_ACCESS_TOKEN }}" >> $GITHUB_ENV
- name: Run all @notesnook/core tests
run: npx nx test:e2e @notesnook/core

View File

@@ -8,7 +8,7 @@ on:
paths:
- "apps/web/**"
# re-run workflow if workflow file changes
- ".github/workflows/web.tests.yml"
- ".github/workflows/web.tests.yml"
pull_request:
types:
- "ready_for_review"
@@ -17,15 +17,18 @@ on:
- "reopened"
jobs:
test:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 16.x
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 16.x
cache: 'npm'
cache: "npm"
cache-dependency-path: |
apps/mobile/package-lock.json
apps/web/package-lock.json
@@ -37,28 +40,84 @@ jobs:
packages/logger/package-lock.json
packages/streamable-fs/package-lock.json
packages/theme/package-lock.json
- name: Install packages
run: |
npm i --ignore-scripts --no-audit
npx lerna bootstrap --ignore=@notesnook/mobile -- --no-audit
- name: Setup environment
run: |
echo "NX_CLOUD_ACCESS_TOKEN=${{ secrets.NX_CLOUD_ACCESS_TOKEN }}" >> $GITHUB_ENV
- name: Generate test build
run: npm run build:test:web
- name: Archive build artifact
uses: actions/upload-artifact@v2
with:
name: build
path: apps/web/build/**/*
test:
needs: build
name: 🧪 Test (${{ matrix.shard }}/${{ strategy.job-total }})
strategy:
matrix:
shard: [1, 2, 3]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download build
uses: actions/download-artifact@v3
with:
name: build
path: ./apps/web/build
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 16.x
cache: "npm"
cache-dependency-path: |
apps/mobile/package-lock.json
apps/web/package-lock.json
packages/core/package-lock.json
packages/crypto/package-lock.json
packages/crypto-worker/package-lock.json
packages/editor-mobile/package-lock.json
packages/editor/package-lock.json
packages/logger/package-lock.json
packages/streamable-fs/package-lock.json
packages/theme/package-lock.json
- name: Install packages
run: |
npm i --ignore-scripts --no-audit
npm install -D @playwright/test
- name: Validate build extraction
run: ls -ld ./apps/web/build/index.html
- name: Install Playwright Browsers
run: npx playwright install chromium --with-deps
working-directory: apps/web
- name: Add environment variables
run: |
echo "USER_EMAIL=${{ secrets.USER_EMAIL }}" >> $GITHUB_ENV
echo "CURRENT_USER_PASSWORD=${{ secrets.USER_PASSWORD }}" >> $GITHUB_ENV
echo "CURRENT_USER_KEY=${{ secrets.USER_KEY }}" >> $GITHUB_ENV
- name: Prepare environment
run: npm ci
- name: Run tests
run: npx playwright test --shard=${{ matrix.shard }}/${{ strategy.job-total }}
working-directory: apps/web
- name: Install Playwright Browsers
run: npx playwright install --with-deps
working-directory: ./apps/web
- name: Generate test build
run: npm run build:test:web
- name: Run all @notesnook/web tests
run: npm run test:web
- uses: actions/upload-artifact@v3
- name: Upload test results
uses: actions/upload-artifact@v3
if: failure()
with:
name: test-results
name: test-results-${{ matrix.shard }}
path: apps/web/test-results
retention-days: 5

3
.gitignore vendored
View File

@@ -2,4 +2,5 @@ build
coverage
node_modules
dist
.DS_STORE
.DS_STORE
nx-cloud.env

View File

@@ -158,10 +158,7 @@ test("select all & backspace should clear all content in editor", async ({
const notes = await app.goToNotes();
const note = await notes.createNote(NOTE);
await notes.editor.editAndWait(async () => {
await notes.editor.selectAll();
await page.keyboard.press("Backspace");
});
await notes.editor.clear();
await notes.newNote();
await note?.openNote();

View File

@@ -137,7 +137,9 @@ test("pressing Shift+ArrowUp should select previous note", async ({ page }) => {
test("use Shift+ArrowUp & Shift+ArrowDown for note selection", async ({
page
}) => {
}, info) => {
info.setTimeout(60 * 1000);
const { notesList, notes } = await populateList(page, 10);
await notes.focus();
// move focus 5 items down
@@ -187,7 +189,9 @@ test("use Shift+ArrowUp & Shift+ArrowDown for note selection", async ({
expect(await notesList[5].isSelected()).toBeTruthy();
});
test("select notes using Control+Click", async ({ page }) => {
test("select notes using Control+Click", async ({ page }, info) => {
info.setTimeout(60 * 1000);
const { notesList, notes } = await populateList(page, 10);
await notes.focus();
@@ -202,7 +206,9 @@ test("select notes using Control+Click", async ({ page }) => {
}
});
test("select notes using Shift+Click downwards", async ({ page }) => {
test("select notes using Shift+Click downwards", async ({ page }, info) => {
info.setTimeout(60 * 1000);
const { notesList, notes } = await populateList(page, 10);
await notes.focus();
@@ -216,7 +222,9 @@ test("select notes using Shift+Click downwards", async ({ page }) => {
expect(await notesList[6].isSelected()).toBeFalsy();
});
test("select notes using Shift+Click upwards", async ({ page }) => {
test("select notes using Shift+Click upwards", async ({ page }, info) => {
info.setTimeout(60 * 1000);
const { notesList, notes } = await populateList(page, 10);
await notes.focus();

View File

@@ -127,6 +127,13 @@ export class EditorModel {
});
}
async clear() {
await this.editAndWait(async () => {
await this.selectAll();
await this.content.press("Backspace");
});
}
async editAndWait(action: () => Promise<void>) {
const oldDateEdited = await this.getDateEdited();
await action();
@@ -154,8 +161,7 @@ export class EditorModel {
async selectAll() {
await this.content.focus();
await this.page.keyboard.press("Home");
await this.page.keyboard.press("Shift+End");
await this.page.keyboard.press("Control+a");
await this.page.waitForTimeout(500);
}

View File

@@ -52,7 +52,7 @@ const NOTE = {
test("edits in a note opened on 2 devices should sync in real-time", async ({
browser
}, info) => {
info.setTimeout(30 * 1000);
info.setTimeout(60 * 1000);
const newContent = makeid(24).repeat(2);
const [deviceA, deviceB] = await Promise.all([
@@ -68,19 +68,16 @@ test("edits in a note opened on 2 devices should sync in real-time", async ({
const noteA = await notesA.findNote(NOTE);
await Promise.all([noteA, noteB].map((note) => note?.openNote()));
const [beforeContentA, beforeContentB] = await Promise.all(
[notesA, notesB].map((notes) => notes?.editor.getContent("text"))
);
await notesB.editor.clear();
await actAndSync([deviceA, deviceB], notesB.editor.setContent(newContent));
const [afterContentA, afterContentB] = await Promise.all(
[notesA, notesB].map((notes) => notes?.editor.getContent("text"))
);
expect(noteA).toBeDefined();
expect(noteB).toBeDefined();
expect(beforeContentA).toBe(beforeContentB);
expect(afterContentA).toBe(`${newContent}${beforeContentA}`);
expect(afterContentB).toBe(`${newContent}${beforeContentB}`);
expect(afterContentA).toBe(newContent);
expect(afterContentB).toBe(newContent);
});
function makeid(length: number) {

View File

@@ -56,7 +56,7 @@
"zustand": "^3.3.1"
},
"devDependencies": {
"@playwright/test": "^1.24.1",
"@playwright/test": "^1.26.0",
"@types/file-saver": "^2.0.5",
"@types/hookrouter": "^2.2.5",
"@types/node-fetch": "^2.5.10",
@@ -3295,12 +3295,13 @@
"link": true
},
"node_modules/@playwright/test": {
"version": "1.25.1",
"version": "1.26.0",
"resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.26.0.tgz",
"integrity": "sha512-D24pu1k/gQw3Lhbpc38G5bXlBjGDrH5A52MsrH12wz6ohGDeQ+aZg/JFSEsT/B3G8zlJe/EU4EkJK74hpqsjEg==",
"dev": true,
"license": "Apache-2.0",
"dependencies": {
"@types/node": "*",
"playwright-core": "1.25.1"
"playwright-core": "1.26.0"
},
"bin": {
"playwright": "cli.js"
@@ -12786,9 +12787,10 @@
"license": "MIT"
},
"node_modules/playwright-core": {
"version": "1.25.1",
"version": "1.26.0",
"resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.26.0.tgz",
"integrity": "sha512-p8huU8eU4gD3VkJd3DA1nA7R3XA6rFvFL+1RYS96cSljCF2yJE9CWEHTPF4LqX8KN9MoWCrAfVKP5381X3CZqg==",
"dev": true,
"license": "Apache-2.0",
"bin": {
"playwright": "cli.js"
},
@@ -19747,11 +19749,13 @@
}
},
"@playwright/test": {
"version": "1.25.1",
"version": "1.26.0",
"resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.26.0.tgz",
"integrity": "sha512-D24pu1k/gQw3Lhbpc38G5bXlBjGDrH5A52MsrH12wz6ohGDeQ+aZg/JFSEsT/B3G8zlJe/EU4EkJK74hpqsjEg==",
"dev": true,
"requires": {
"@types/node": "*",
"playwright-core": "1.25.1"
"playwright-core": "1.26.0"
}
},
"@pmmmwh/react-refresh-webpack-plugin": {
@@ -25693,7 +25697,9 @@
"version": "1.3.6"
},
"playwright-core": {
"version": "1.25.1",
"version": "1.26.0",
"resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.26.0.tgz",
"integrity": "sha512-p8huU8eU4gD3VkJd3DA1nA7R3XA6rFvFL+1RYS96cSljCF2yJE9CWEHTPF4LqX8KN9MoWCrAfVKP5381X3CZqg==",
"dev": true
},
"plist": {

View File

@@ -62,7 +62,7 @@
"zustand": "^3.3.1"
},
"devDependencies": {
"@playwright/test": "^1.24.1",
"@playwright/test": "^1.26.0",
"@types/file-saver": "^2.0.5",
"@types/hookrouter": "^2.2.5",
"@types/node-fetch": "^2.5.10",
@@ -99,14 +99,13 @@
"start:desktop": "env-cmd -e all,desktop react-scripts start",
"start:test": "serve -s build/ -p 3000",
"build": "env-cmd -e all,web react-scripts --max_old_space_size=8092 build",
"build:test": "env-cmd -e all,dev,web,silent react-scripts build",
"build:test": "env-cmd -e all,dev,web,silent react-scripts build --test",
"build:beta": "env-cmd -e all,web,beta react-scripts build",
"build:profile": "env-cmd -e all,web react-scripts build --profile",
"build:desktop": "env-cmd -e all,desktop react-scripts build",
"deploy": "./scripts/deploy.sh",
"debug": "env-cmd -e all,dev,web,silent react-scripts start",
"test": "playwright test",
"test:all": "env-cmd -e test playwright test",
"eject": "react-scripts eject",
"analyze": "source-map-explorer 'build/static/js/*.js'",
"postinstall": "patch-package"
@@ -133,14 +132,5 @@
},
"volta": {
"node": "16.15.1"
},
"nx": {
"targets": {
"build": {
"outputs": [
"{projectRoot}/build"
]
}
}
}
}

View File

@@ -1,8 +1,27 @@
diff --git a/node_modules/react-scripts/config/webpack.config.js b/node_modules/react-scripts/config/webpack.config.js
index e465d8e..7a393f6 100644
index e465d8e..769f0dd 100644
--- a/node_modules/react-scripts/config/webpack.config.js
+++ b/node_modules/react-scripts/config/webpack.config.js
@@ -304,6 +304,13 @@ module.exports = function (webpackEnv) {
@@ -106,6 +106,9 @@ module.exports = function (webpackEnv) {
const isEnvProductionProfile =
isEnvProduction && process.argv.includes('--profile');
+ const isEnvProductionTest =
+ isEnvProduction && process.argv.includes('--test');
+
// We will provide `paths.publicUrlOrPath` to our app
// as %PUBLIC_URL% in `index.html` and `process.env.PUBLIC_URL` in JavaScript.
// Omit trailing slash as %PUBLIC_URL%/xyz looks better than %PUBLIC_URL%xyz.
@@ -256,7 +259,7 @@ module.exports = function (webpackEnv) {
level: 'none',
},
optimization: {
- minimize: isEnvProduction,
+ minimize: isEnvProduction && !isEnvProductionTest,
minimizer: [
// This is only used in production mode
new TerserPlugin({
@@ -304,6 +307,13 @@ module.exports = function (webpackEnv) {
},
resolve: {
// This allows you to set a fallback for where webpack should look for modules.
@@ -16,16 +35,24 @@ index e465d8e..7a393f6 100644
// We placed these paths second because we want `node_modules` to "win"
// if there are any conflicts. This matches Node resolution mechanism.
// https://github.com/facebook/create-react-app/issues/253
@@ -327,6 +334,8 @@ module.exports = function (webpackEnv) {
@@ -320,13 +330,15 @@ module.exports = function (webpackEnv) {
.map(ext => `.${ext}`)
.filter(ext => useTypeScript || !ext.includes('ts')),
alias: {
+ "react": path.resolve(path.join(__dirname,'../../react')),
+ "react-dom": path.resolve(path.join(__dirname,'../../react-dom')),
// Support React Native Web
// https://www.smashingmagazine.com/2016/08/a-glimpse-into-the-future-with-react-native-for-web/
'react-native': 'react-native-web',
// Allows for better profiling with ReactDevTools
...(isEnvProductionProfile && {
'react-dom$': 'react-dom/profiling',
'scheduler/tracing': 'scheduler/tracing-profiling',
+ "react": path.resolve(path.join(__dirname,'../../react')),
+ "react-dom": path.resolve(path.join(__dirname,'../../react-dom'))
- 'scheduler/tracing': 'scheduler/tracing-profiling',
+ 'scheduler/tracing': 'scheduler/tracing-profiling'
}),
...(modules.webpackAliases || {}),
},
@@ -336,14 +345,14 @@ module.exports = function (webpackEnv) {
@@ -336,14 +348,14 @@ module.exports = function (webpackEnv) {
// To fix this, we prevent you from importing files out of src/ -- if you'd like to,
// please link the files into your node_modules/ and let module-resolution kick in.
// Make sure your source files are compiled, as they will not be processed in any way.

View File

@@ -35,7 +35,7 @@ const config: PlaywrightTestConfig = {
timeout: IS_CI ? 30000 : 15000,
workers: IS_CI ? 2 : 2,
reporter: "list",
retries: IS_CI ? 0 : 0,
retries: IS_CI ? 1 : 0,
fullyParallel: true,
preserveOutput: "failures-only",
outputDir: "test-results",

11
nx.json
View File

@@ -1,18 +1,21 @@
{
"tasksRunnerOptions": {
"default": {
"runner": "nx/tasks-runners/default",
"runner": "@nrwl/nx-cloud",
"options": {
"cacheableOperations": ["build", "start"]
"cacheableOperations": ["build", "build:test"],
"accessToken": "ZWM3ODgxNDgtNGUzZC00MjQ0LWE3MzMtZDdhMzE3ZGY2MWFlfHJlYWQ="
}
}
},
"targetDefaults": {
"build": {
"dependsOn": ["^build"]
"dependsOn": ["^build"],
"outputs": ["{projectRoot}/build", "{projectRoot}/dist"]
},
"build:test": {
"dependsOn": ["^build"]
"dependsOn": ["^build"],
"outputs": ["{projectRoot}/build"]
},
"start": {
"dependsOn": ["^build"]

147
package-lock.json generated
View File

@@ -6,6 +6,7 @@
"": {
"name": "notesnook",
"dependencies": {
"@nrwl/nx-cloud": "^14.6.2",
"eslint-plugin-header": "^3.1.1"
},
"devDependencies": {
@@ -3809,6 +3810,46 @@
"nx": "14.5.10"
}
},
"node_modules/@nrwl/nx-cloud": {
"version": "14.6.2",
"resolved": "https://registry.npmjs.org/@nrwl/nx-cloud/-/nx-cloud-14.6.2.tgz",
"integrity": "sha512-w8ujbFMOxE7lJg52O3JjnpTGlBKc+/vovxVTplIfGU9TYgEgAo/v4HS9svztzGd9Era7qmNaoYOmxm6Ebtbo5g==",
"dependencies": {
"axios": "^0.21.1",
"chalk": "4.1.0",
"dotenv": "~10.0.0",
"node-machine-id": "^1.1.12",
"strip-json-comments": "^3.1.1",
"tar": "6.1.11",
"yargs-parser": ">=21.0.1"
},
"bin": {
"nx-cloud": "bin/nx-cloud.js"
}
},
"node_modules/@nrwl/nx-cloud/node_modules/chalk": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz",
"integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==",
"dependencies": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
},
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/chalk/chalk?sponsor=1"
}
},
"node_modules/@nrwl/nx-cloud/node_modules/yargs-parser": {
"version": "21.1.1",
"resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz",
"integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==",
"engines": {
"node": ">=12"
}
},
"node_modules/@nrwl/tao": {
"version": "14.5.10",
"resolved": "https://registry.npmjs.org/@nrwl/tao/-/tao-14.5.10.tgz",
@@ -4676,6 +4717,14 @@
"node": ">=4"
}
},
"node_modules/axios": {
"version": "0.21.4",
"resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz",
"integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==",
"dependencies": {
"follow-redirects": "^1.14.0"
}
},
"node_modules/axobject-query": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/axobject-query/-/axobject-query-2.2.0.tgz",
@@ -5262,7 +5311,6 @@
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz",
"integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==",
"dev": true,
"engines": {
"node": ">=10"
}
@@ -6045,7 +6093,6 @@
"version": "10.0.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-10.0.0.tgz",
"integrity": "sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q==",
"dev": true,
"engines": {
"node": ">=10"
}
@@ -7134,6 +7181,25 @@
"resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz",
"integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ=="
},
"node_modules/follow-redirects": {
"version": "1.15.2",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz",
"integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==",
"funding": [
{
"type": "individual",
"url": "https://github.com/sponsors/RubenVerborgh"
}
],
"engines": {
"node": ">=4.0"
},
"peerDependenciesMeta": {
"debug": {
"optional": true
}
}
},
"node_modules/formdata-polyfill": {
"version": "4.0.10",
"resolved": "https://registry.npmjs.org/formdata-polyfill/-/formdata-polyfill-4.0.10.tgz",
@@ -7177,7 +7243,6 @@
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz",
"integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==",
"dev": true,
"dependencies": {
"minipass": "^3.0.0"
},
@@ -9135,7 +9200,6 @@
"version": "3.3.4",
"resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.4.tgz",
"integrity": "sha512-I9WPbWHCGu8W+6k1ZiGpPu0GkoKBeorkfKNuAFBNS1HNFJvke82sxvI5bzcCNpWPorkOO5QQ+zomzzwRxejXiw==",
"dev": true,
"dependencies": {
"yallist": "^4.0.0"
},
@@ -9222,7 +9286,6 @@
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz",
"integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==",
"dev": true,
"dependencies": {
"minipass": "^3.0.0",
"yallist": "^4.0.0"
@@ -9235,7 +9298,6 @@
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz",
"integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==",
"dev": true,
"bin": {
"mkdirp": "bin/cmd.js"
},
@@ -9447,6 +9509,11 @@
"url": "https://github.com/sponsors/isaacs"
}
},
"node_modules/node-machine-id": {
"version": "1.1.12",
"resolved": "https://registry.npmjs.org/node-machine-id/-/node-machine-id-1.1.12.tgz",
"integrity": "sha512-QNABxbrPa3qEIfrE6GOJ7BYIuignnJw7iQ2YPbc3Nla1HzRJjXzZOiikfF8m7eAMfichLt3M4VgLOetqgDmgGQ=="
},
"node_modules/node-releases": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.6.tgz",
@@ -11882,7 +11949,6 @@
"version": "6.1.11",
"resolved": "https://registry.npmjs.org/tar/-/tar-6.1.11.tgz",
"integrity": "sha512-an/KZQzQUkZCkuoAA64hM92X0Urb6VpRhAFllDzz44U2mcD5scmT3zBc4VgVpkugF580+DQn8eAFSyoQt0tznA==",
"dev": true,
"dependencies": {
"chownr": "^2.0.0",
"fs-minipass": "^2.0.0",
@@ -12738,8 +12804,7 @@
"node_modules/yallist": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==",
"dev": true
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
},
"node_modules/yaml": {
"version": "1.10.2",
@@ -15746,6 +15811,36 @@
"nx": "14.5.10"
}
},
"@nrwl/nx-cloud": {
"version": "14.6.2",
"resolved": "https://registry.npmjs.org/@nrwl/nx-cloud/-/nx-cloud-14.6.2.tgz",
"integrity": "sha512-w8ujbFMOxE7lJg52O3JjnpTGlBKc+/vovxVTplIfGU9TYgEgAo/v4HS9svztzGd9Era7qmNaoYOmxm6Ebtbo5g==",
"requires": {
"axios": "^0.21.1",
"chalk": "4.1.0",
"dotenv": "~10.0.0",
"node-machine-id": "^1.1.12",
"strip-json-comments": "^3.1.1",
"tar": "6.1.11",
"yargs-parser": ">=21.0.1"
},
"dependencies": {
"chalk": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz",
"integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==",
"requires": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
}
},
"yargs-parser": {
"version": "21.1.1",
"resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz",
"integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw=="
}
}
},
"@nrwl/tao": {
"version": "14.5.10",
"resolved": "https://registry.npmjs.org/@nrwl/tao/-/tao-14.5.10.tgz",
@@ -16364,6 +16459,14 @@
"integrity": "sha512-32+ub6kkdhhWick/UjvEwRchgoetXqTK14INLqbGm5U2TzBkBNF3nQtLYm8ovxSkQWArjEQvftCKryjZaATu3w==",
"dev": true
},
"axios": {
"version": "0.21.4",
"resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz",
"integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==",
"requires": {
"follow-redirects": "^1.14.0"
}
},
"axobject-query": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/axobject-query/-/axobject-query-2.2.0.tgz",
@@ -16772,8 +16875,7 @@
"chownr": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz",
"integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==",
"dev": true
"integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ=="
},
"ci-info": {
"version": "2.0.0",
@@ -17381,8 +17483,7 @@
"dotenv": {
"version": "10.0.0",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-10.0.0.tgz",
"integrity": "sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q==",
"dev": true
"integrity": "sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q=="
},
"duplexer": {
"version": "0.1.2",
@@ -18202,6 +18303,11 @@
"resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz",
"integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ=="
},
"follow-redirects": {
"version": "1.15.2",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz",
"integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA=="
},
"formdata-polyfill": {
"version": "4.0.10",
"resolved": "https://registry.npmjs.org/formdata-polyfill/-/formdata-polyfill-4.0.10.tgz",
@@ -18239,7 +18345,6 @@
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz",
"integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==",
"dev": true,
"requires": {
"minipass": "^3.0.0"
}
@@ -19715,7 +19820,6 @@
"version": "3.3.4",
"resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.4.tgz",
"integrity": "sha512-I9WPbWHCGu8W+6k1ZiGpPu0GkoKBeorkfKNuAFBNS1HNFJvke82sxvI5bzcCNpWPorkOO5QQ+zomzzwRxejXiw==",
"dev": true,
"requires": {
"yallist": "^4.0.0"
}
@@ -19782,7 +19886,6 @@
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz",
"integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==",
"dev": true,
"requires": {
"minipass": "^3.0.0",
"yallist": "^4.0.0"
@@ -19791,8 +19894,7 @@
"mkdirp": {
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz",
"integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==",
"dev": true
"integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw=="
},
"mkdirp-infer-owner": {
"version": "2.0.0",
@@ -19945,6 +20047,11 @@
"integrity": "sha512-2iGbaQBV+ITgCz76ZEjmhUKAKVf7xfY1sRl4UiKQspfZMH2h06SyhNsnSVy50cwkFQDGLyif6m/6uFXHkOZ6rg==",
"dev": true
},
"node-machine-id": {
"version": "1.1.12",
"resolved": "https://registry.npmjs.org/node-machine-id/-/node-machine-id-1.1.12.tgz",
"integrity": "sha512-QNABxbrPa3qEIfrE6GOJ7BYIuignnJw7iQ2YPbc3Nla1HzRJjXzZOiikfF8m7eAMfichLt3M4VgLOetqgDmgGQ=="
},
"node-releases": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.6.tgz",
@@ -21770,7 +21877,6 @@
"version": "6.1.11",
"resolved": "https://registry.npmjs.org/tar/-/tar-6.1.11.tgz",
"integrity": "sha512-an/KZQzQUkZCkuoAA64hM92X0Urb6VpRhAFllDzz44U2mcD5scmT3zBc4VgVpkugF580+DQn8eAFSyoQt0tznA==",
"dev": true,
"requires": {
"chownr": "^2.0.0",
"fs-minipass": "^2.0.0",
@@ -22407,8 +22513,7 @@
"yallist": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==",
"dev": true
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
},
"yaml": {
"version": "1.10.2",

View File

@@ -3,7 +3,7 @@
"private": true,
"scripts": {
"prepare": "husky install && npm run bootstrap",
"bootstrap": "lerna bootstrap -- --legacy-peer-deps",
"bootstrap": "lerna bootstrap -- --legacy-peer-deps --no-audit",
"build": "nx run-many --target=build --all --exclude=@notesnook/mobile,@notesnook/web",
"build:web": "nx build @notesnook/web",
"build:test:web": "nx build:test @notesnook/web",
@@ -51,6 +51,7 @@
"zx": "^7.0.8"
},
"dependencies": {
"@nrwl/nx-cloud": "^14.6.2",
"eslint-plugin-header": "^3.1.1"
}
}