Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 01abdfcbb6 | |||
| 82d02516fe |
@@ -8,5 +8,22 @@
|
|||||||
"semi": false,
|
"semi": false,
|
||||||
"bracketSpacing": true,
|
"bracketSpacing": true,
|
||||||
"arrowParens": "always",
|
"arrowParens": "always",
|
||||||
"endOfLine": "lf"
|
"endOfLine": "lf",
|
||||||
|
"plugins": ["@ianvs/prettier-plugin-sort-imports"],
|
||||||
|
"importOrderParserPlugins": ["typescript", "jsx", "classProperties", "decorators-legacy"],
|
||||||
|
"importOrder": [
|
||||||
|
"^react$",
|
||||||
|
"",
|
||||||
|
"<BUILTIN_MODULES>",
|
||||||
|
"<THIRD_PARTY_MODULES>",
|
||||||
|
"",
|
||||||
|
"^@/[^/]+(/.*)?$",
|
||||||
|
"",
|
||||||
|
"^(?!.*[.](css|less)$)[./].*$",
|
||||||
|
"",
|
||||||
|
".*\\.(css|less)$"
|
||||||
|
],
|
||||||
|
"importOrderSeparation": true,
|
||||||
|
"importOrderSortSpecifiers": true,
|
||||||
|
"importOrderCombineTypeAndValueImports": true
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
import js from '@eslint/js'
|
import js from '@eslint/js'
|
||||||
import prettierConfig from 'eslint-config-prettier'
|
import prettierConfig from 'eslint-config-prettier'
|
||||||
import importPlugin from 'eslint-plugin-import'
|
|
||||||
import prettierPlugin from 'eslint-plugin-prettier'
|
import prettierPlugin from 'eslint-plugin-prettier'
|
||||||
import reactHooks from 'eslint-plugin-react-hooks'
|
import reactHooks from 'eslint-plugin-react-hooks'
|
||||||
import reactRefresh from 'eslint-plugin-react-refresh'
|
import reactRefresh from 'eslint-plugin-react-refresh'
|
||||||
@@ -20,7 +19,6 @@ export default [
|
|||||||
'react-hooks': reactHooks,
|
'react-hooks': reactHooks,
|
||||||
'react-refresh': reactRefresh,
|
'react-refresh': reactRefresh,
|
||||||
prettier: prettierPlugin,
|
prettier: prettierPlugin,
|
||||||
import: importPlugin,
|
|
||||||
},
|
},
|
||||||
languageOptions: {
|
languageOptions: {
|
||||||
ecmaVersion: 2020,
|
ecmaVersion: 2020,
|
||||||
@@ -31,18 +29,7 @@ export default [
|
|||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
...reactHooks.configs.recommended.rules,
|
...reactHooks.configs.recommended.rules,
|
||||||
'prettier/prettier': ['error', { endOfLine: 'auto' }],
|
'prettier/prettier': ['error'],
|
||||||
'import/order': [
|
|
||||||
'error',
|
|
||||||
{
|
|
||||||
groups: [['builtin', 'external'], 'internal', ['parent', 'sibling', 'index']],
|
|
||||||
'newlines-between': 'always',
|
|
||||||
alphabetize: {
|
|
||||||
order: 'asc',
|
|
||||||
caseInsensitive: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
prettierConfig,
|
prettierConfig,
|
||||||
|
|||||||
@@ -14,28 +14,23 @@
|
|||||||
"type-check": "vue-tsc --build"
|
"type-check": "vue-tsc --build"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mantine/core": "^8.3.1",
|
|
||||||
"@mantine/hooks": "^8.3.1",
|
|
||||||
"react": "^19.1.1",
|
"react": "^19.1.1",
|
||||||
"react-dom": "^19.1.1"
|
"react-dom": "^19.1.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@eslint/js": "^9.33.0",
|
"@eslint/js": "^9.33.0",
|
||||||
|
"@ianvs/prettier-plugin-sort-imports": "^4.7.0",
|
||||||
|
"@trivago/prettier-plugin-sort-imports": "^5.2.2",
|
||||||
"@types/react": "^19.1.10",
|
"@types/react": "^19.1.10",
|
||||||
"@types/react-dom": "^19.1.7",
|
"@types/react-dom": "^19.1.7",
|
||||||
"@vitejs/plugin-react-swc": "^4.0.0",
|
"@vitejs/plugin-react-swc": "^4.0.0",
|
||||||
"eslint": "^9.33.0",
|
"eslint": "^9.33.0",
|
||||||
"eslint-config-prettier": "^10.1.8",
|
"eslint-config-prettier": "^10.1.8",
|
||||||
"eslint-plugin-import": "^2.32.0",
|
|
||||||
"eslint-plugin-prettier": "^5.5.4",
|
"eslint-plugin-prettier": "^5.5.4",
|
||||||
"eslint-plugin-react": "^7.37.5",
|
"eslint-plugin-react": "^7.37.5",
|
||||||
"eslint-plugin-react-hooks": "^5.2.0",
|
"eslint-plugin-react-hooks": "^5.2.0",
|
||||||
"eslint-plugin-react-refresh": "^0.4.20",
|
"eslint-plugin-react-refresh": "^0.4.20",
|
||||||
"globals": "^16.3.0",
|
"globals": "^16.3.0",
|
||||||
"less": "^4.4.1",
|
|
||||||
"postcss": "^8.5.6",
|
|
||||||
"postcss-preset-mantine": "^1.18.0",
|
|
||||||
"postcss-simple-vars": "^7.0.1",
|
|
||||||
"prettier": "^3.6.2",
|
"prettier": "^3.6.2",
|
||||||
"typescript": "~5.8.3",
|
"typescript": "~5.8.3",
|
||||||
"typescript-eslint": "^8.39.1",
|
"typescript-eslint": "^8.39.1",
|
||||||
|
|||||||
875
pnpm-lock.yaml
generated
875
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@@ -1,14 +0,0 @@
|
|||||||
export default {
|
|
||||||
plugins: {
|
|
||||||
'postcss-preset-mantine': {},
|
|
||||||
'postcss-simple-vars': {
|
|
||||||
variables: {
|
|
||||||
'mantine-breakpoint-xs': '36em',
|
|
||||||
'mantine-breakpoint-sm': '48em',
|
|
||||||
'mantine-breakpoint-md': '62em',
|
|
||||||
'mantine-breakpoint-lg': '75em',
|
|
||||||
'mantine-breakpoint-xl': '88em',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
@import "@mantine/core/styles.css";
|
|
||||||
|
|||||||
19
src/main.tsx
19
src/main.tsx
@@ -1,24 +1,13 @@
|
|||||||
import { createTheme, MantineProvider } from '@mantine/core'
|
|
||||||
import { StrictMode } from 'react'
|
import { StrictMode } from 'react'
|
||||||
|
|
||||||
import { createRoot } from 'react-dom/client'
|
import { createRoot } from 'react-dom/client'
|
||||||
|
|
||||||
import Home from '@/pages/home/index'
|
import Home from '@/pages/home/index'
|
||||||
|
|
||||||
import './index.css'
|
import './index.css'
|
||||||
|
|
||||||
const theme = createTheme({
|
createRoot(document.getElementById('root')!).render(
|
||||||
/** Put your mantine theme override here */
|
|
||||||
})
|
|
||||||
|
|
||||||
function App() {
|
|
||||||
return (
|
|
||||||
<StrictMode>
|
<StrictMode>
|
||||||
<MantineProvider theme={theme}>
|
|
||||||
<Home />
|
<Home />
|
||||||
</MantineProvider>
|
</StrictMode>,
|
||||||
</StrictMode>
|
)
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
const root = createRoot(document.getElementById('root')!)
|
|
||||||
root.render(<App />)
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
import { Button } from '@mantine/core'
|
|
||||||
import { useEffect, useState } from 'react'
|
import { useEffect, useState } from 'react'
|
||||||
|
|
||||||
export default function Home() {
|
export default function Home() {
|
||||||
@@ -9,9 +8,5 @@ export default function Home() {
|
|||||||
}, [])
|
}, [])
|
||||||
console.log(num)
|
console.log(num)
|
||||||
|
|
||||||
return (
|
return <div>home</div>
|
||||||
<div>
|
|
||||||
<Button variant='filled'>Button</Button>;
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user