Skip to content

Commit

Permalink
fix(ci): fix ci lint step (#2988)
Browse files Browse the repository at this point in the history
Co-authored-by: nihalgonsalves <nihal@nihalgonsalves.com>
  • Loading branch information
Shinigami92 and nihalgonsalves committed May 5, 2021
1 parent 1e604d5 commit 4e8ffd8
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
run: yarn install --frozen-lockfile

- name: Build vite
run: yarn build-vite
run: yarn ci-build-vite

- name: Build plugin-vue
run: yarn build-plugin-vue
Expand Down Expand Up @@ -91,7 +91,7 @@ jobs:
- name: Prepare
run: |
yarn install --frozen-lockfile
yarn build-vite
yarn ci-build-vite
yarn build-plugin-vue
- name: Lint
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"build": "run-s build-vite build-plugin-vue",
"build-vite": "cd packages/vite && yarn build",
"build-plugin-vue": "cd packages/plugin-vue && yarn build",
"ci-build-vite": "cd packages/vite && yarn ci-build",
"ci-docs": "run-s build-vite build-plugin-vue build-docs"
},
"devDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-react-refresh/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,8 @@ function isRefreshBoundary(ast) {
const { declaration, specifiers } = node
if (declaration) {
if (declaration.type === 'VariableDeclaration') {
return declaration.declarations.every(
(variable) => isComponentLikeIdentifier(variable.id)
return declaration.declarations.every((variable) =>
isComponentLikeIdentifier(variable.id)
)
}
if (declaration.type === 'FunctionDeclaration') {
Expand Down
1 change: 1 addition & 0 deletions packages/vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
"build-bundle": "rollup -c",
"build-types": "run-s build-temp-types patch-types roll-types",
"build-temp-types": "tsc --emitDeclarationOnly --outDir temp/node -p src/node",
"ci-build": "rimraf dist && yarn run-s build-bundle build-types",
"patch-types": "node scripts/patchTypes",
"roll-types": "api-extractor run && rimraf temp",
"lint": "eslint --ext .ts src/**",
Expand Down
3 changes: 2 additions & 1 deletion scripts/jestPerTestSetup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const isBuildTest = !!process.env.VITE_TEST_BUILD

// injected by the test env
declare global {
// eslint-disable-next-line @typescript-eslint/no-namespace
namespace NodeJS {
interface Global {
page?: Page
Expand Down Expand Up @@ -102,7 +103,7 @@ beforeAll(async () => {
// https://github.com/facebook/jest/issues/2713
err = e

// Closing the page since an error in the setup, for example a runtime error
// Closing the page since an error in the setup, for example a runtime error
// when building the playground should skip further tests.
// If the page remains open, a command like `await page.click(...)` produces
// a timeout with an exception that hides the real error in the console.
Expand Down

0 comments on commit 4e8ffd8

Please sign in to comment.