diff --git a/.circleci/config.yml b/.circleci/config.yml index e2455caf6..7271fd0b7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -18,18 +18,18 @@ jobs: install-dependencies: <<: *work-dir docker: - - image: circleci/node:14 + - image: cimg/node:17.9 environment: HUSKY_SKIP_INSTALL: 1 steps: - checkout - restore_cache: - key: v1-deps-{{ checksum "yarn.lock" }} + key: v3-deps-{{ checksum "yarn.lock" }} - run: name: Install dependencies command: yarn install - save_cache: - key: v1-deps-{{ checksum "yarn.lock" }} + key: v3-deps-{{ checksum "yarn.lock" }} paths: - node_modules - *persist-step @@ -37,7 +37,7 @@ jobs: build: <<: *work-dir docker: - - image: circleci/node:latest + - image: cimg/node:17.9 steps: - *attach-step - run: @@ -47,17 +47,17 @@ jobs: lint: <<: *work-dir docker: - - image: circleci/node:14 + - image: cimg/node:17.9 steps: - *attach-step - run: name: lint command: yarn lint - test-node-16: + test-node: <<: *work-dir docker: - - image: circleci/node:16 + - image: cimg/node:17.9 steps: - *attach-step - run: @@ -74,7 +74,7 @@ jobs: publish-coverage: <<: *work-dir docker: - - image: circleci/node:latest + - image: cimg/node:17.9 steps: - *attach-step - run: @@ -105,7 +105,7 @@ workflows: branches: ignore: gh-pages - - test-node-16: + - test-node: requires: - build filters: @@ -114,7 +114,7 @@ workflows: - publish-coverage: requires: - - test-node-16 + - test-node filters: branches: diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile new file mode 100644 index 000000000..62d757bf0 --- /dev/null +++ b/.devcontainer/Dockerfile @@ -0,0 +1,16 @@ +# See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.194.3/containers/javascript-node/.devcontainer/base.Dockerfile + +# [Choice] Node.js version: 16, 14, 12, 16-bullseye, 14-bullseye, 12-bullseye, 16-buster, 14-buster, 12-buster +ARG VARIANT="16-bullseye" +FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT} + +# [Optional] Uncomment this section to install additional OS packages. +# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \ +# && apt-get -y install --no-install-recommends + +# [Optional] Uncomment if you want to install an additional version of node using nvm +# ARG EXTRA_NODE_VERSION=10 +# RUN su node -c "source /usr/local/share/nvm/nvm.sh && nvm install ${EXTRA_NODE_VERSION}" + +# [Optional] Uncomment if you want to install more global node modules +# RUN su node -c "npm install -g " diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 000000000..1a0700b1a --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,29 @@ +// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at: +// https://github.com/microsoft/vscode-dev-containers/tree/v0.194.3/containers/javascript-node +{ + "name": "Node.js", + "build": { + "dockerfile": "Dockerfile", + // Update 'VARIANT' to pick a Node version: 16, 14, 12. + // Append -bullseye or -buster to pin to an OS version. + // Use the -bullseye variants if you are on a M1 mac. + "args": { "VARIANT": "16-bullseye" } + }, + + // Set *default* container specific settings.json values on container create. + "settings": {}, + + // Add the IDs of extensions you want installed when the container is created. + "extensions": [ + "dbaeumer.vscode-eslint" + ], + + // Use 'forwardPorts' to make a list of ports inside the container available locally. + // "forwardPorts": [], + + // Use 'postCreateCommand' to run commands after the container is created. + // "postCreateCommand": "yarn install", + + // Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root. + "remoteUser": "node" +} diff --git a/.eslintignore b/.eslintignore index 60220b496..37898312f 100644 --- a/.eslintignore +++ b/.eslintignore @@ -7,5 +7,4 @@ website/build website/node_modules website/i18n/*.js website/static -!.eslintrc.js -tests/ \ No newline at end of file +!.eslintrc.js \ No newline at end of file diff --git a/.eslintrc.js b/.eslintrc.js index da732c539..1d29a27e5 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,6 +1,8 @@ module.exports = { env: { node: true, + jasmine: true, + jest: true, }, extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended"], parser: "@typescript-eslint/parser", @@ -11,10 +13,13 @@ module.exports = { plugins: ["@typescript-eslint"], rules: { "no-console": "error", - quotes: ["error", "double"], + "no-inner-declarations": "off", + quotes: ["off"], "space-before-function-paren": "off", "no-unused-vars": "off", "comma-dangle": "off", + "@typescript-eslint/ban-ts-comment": "off", + "@typescript-eslint/no-empty-function": "off", "@typescript-eslint/no-empty-interface": "off", "@typescript-eslint/no-unused-vars": "error", "@typescript-eslint/explicit-module-boundary-types": "off", diff --git a/.gitattributes b/.gitattributes index 58378fc18..30bd83406 100644 --- a/.gitattributes +++ b/.gitattributes @@ -4,6 +4,7 @@ eol=lf * text=auto eol=lf *.mdx text linguist-detectable +*.env text linguist-detectable # JS and TS files must always use LF for tools to work *.js eol=lf diff --git a/.github/ISSUE_TEMPLATE/new_cli_command.md b/.github/ISSUE_TEMPLATE/new_cli_command.md new file mode 100644 index 000000000..c210da58b --- /dev/null +++ b/.github/ISSUE_TEMPLATE/new_cli_command.md @@ -0,0 +1,31 @@ +--- +name: New CLI Command +about: Suggest a new CLI command +title: "" +labels: "" +assignees: "" +--- + +### Description + + + +### Terminology + +```shell +corde