Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add oxlint #22

Merged
merged 14 commits into from
Jan 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ require('@rushstack/eslint-patch/modern-module-resolution')

module.exports = {
root: true,
'ignorePatterns': ['*.config.js'],
'extends': ['plugin:vue/vue3-essential', 'eslint:recommended', '@vue/eslint-config-typescript', '@vue/eslint-config-prettier/skip-formatting', 'plugin:storybook/recommended'],
parserOptions: {
ecmaVersion: 'latest'
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ jobs:
run: bun --version
- name: Install dependencies
run: bun install --frozen-lockfile
- name: lint
run: bun run lint && bun run eslint
- name: unit test
run: bun run test:unit
# - name: e2e test
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ coverage
test-results/
playwright-report/
vitest-result/
storybook-static/
e2e/*-snapshots/

*~
/public/v.js
Binary file modified bun.lockb
Binary file not shown.
9 changes: 6 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,12 @@
"build-only": "vite build",
"make404": "cp dist/index.html dist/404.html",
"type-check": "vue-tsc --noEmit -p tsconfig.vitest.json --composite false",
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore",
"lint": "oxlint",
"eslint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore",
"format": "prettier --write src/",
"storybook": "storybook dev -p 6006",
"build-storybook": "storybook build"
"storybook": "storybook dev -h 0.0.0.0 -p 6006",
"storybook:build": "storybook build",
"storybook:preview-built": "vite preview --host 0.0.0.0 -p 8080 --outDir storybook-static"
},
"dependencies": {
"pinia": "^2.1.7",
Expand Down Expand Up @@ -58,6 +60,7 @@
"eslint-plugin-vue": "^9.17.0",
"jsdom": "^22.1.0",
"npm-run-all2": "^6.1.1",
"oxlint": "^0.0.22",
"postcss": "^8.4.31",
"prettier": "^3.0.3",
"react": "^18.2.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { Meta, StoryObj } from '@storybook/vue3'

import Button from './Button.vue'
import Button from './SampleButton.vue'

// More on how to set up stories at: https://storybook.js.org/docs/writing-stories
const meta = {
Expand Down
2 changes: 1 addition & 1 deletion src/stories/Button.vue → src/stories/SampleButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
</template>

<script lang="ts" setup>
import './button.css'
import './sample-button.css'
import { computed } from 'vue'
const props = withDefaults(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { Meta, StoryObj } from '@storybook/vue3'

import MyHeader from './Header.vue'
import MyHeader from './SampleHeader.vue'

const meta = {
/* 👇 The title prop is optional.
Expand Down
4 changes: 2 additions & 2 deletions src/stories/Header.vue → src/stories/SampleHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
</template>

<script lang="ts" setup>
import './header.css'
import MyButton from './Button.vue'
import './sample-header.css'
import MyButton from './SampleButton.vue'

defineProps<{ user: { name: string } | null }>()

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { Meta, StoryObj } from '@storybook/vue3'
import { within, userEvent, expect } from '@storybook/test'
import MyPage from './Page.vue'
import MyPage from './SamplePage.vue'

const meta = {
title: 'Example/Page',
Expand Down
4 changes: 2 additions & 2 deletions src/stories/Page.vue → src/stories/SamplePage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@
</template>

<script lang="ts" setup>
import './page.css'
import MyHeader from './Header.vue'
import './sample-page.css'
import MyHeader from './SampleHeader.vue'
import { ref } from 'vue'
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading