Fix eslint setup
This commit is contained in:
7
.vscode/settings.json
vendored
7
.vscode/settings.json
vendored
@@ -22,10 +22,5 @@
|
||||
"jsonc",
|
||||
"yaml",
|
||||
"toml"
|
||||
],
|
||||
|
||||
// Use .config directory
|
||||
"eslint.options": {
|
||||
"overrideConfigFile": ".config/eslint.mjs"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
@@ -1,44 +1,44 @@
|
||||
import { antfu as eslintConfig } from "@antfu/eslint-config";
|
||||
import withNuxt from "./.nuxt/eslint.config.mjs";
|
||||
import eslintConfig from "@antfu/eslint-config";
|
||||
import nuxtConfig from "./.nuxt/eslint.config.mjs";
|
||||
|
||||
export default withNuxt(
|
||||
eslintConfig(
|
||||
// General
|
||||
{
|
||||
typescript: true,
|
||||
vue: true,
|
||||
unocss: true,
|
||||
stylistic: {
|
||||
indent: "tab",
|
||||
quotes: "double"
|
||||
},
|
||||
rules: {
|
||||
curly: "off",
|
||||
"no-console": "off",
|
||||
"no-new-func": "off",
|
||||
"style/semi": ["error", "always"],
|
||||
"style/indent": ["error", "tab"],
|
||||
"style/quote-props": ["warn", "as-needed"],
|
||||
"style/comma-dangle": ["warn", "never"],
|
||||
"style/brace-style": ["warn", "1tbs"],
|
||||
"style/arrow-parens": ["error", "always"],
|
||||
"vue/block-order": ["error", {
|
||||
order: ["template", "script", "style"]
|
||||
}],
|
||||
"vue/script-indent": ["error", "tab", {
|
||||
baseIndent: 1
|
||||
}],
|
||||
"antfu/top-level-function": "off",
|
||||
"node/prefer-global/process": ["off"]
|
||||
}
|
||||
export default eslintConfig(
|
||||
// General
|
||||
{
|
||||
typescript: true,
|
||||
vue: true,
|
||||
unocss: true,
|
||||
stylistic: {
|
||||
indent: "tab",
|
||||
quotes: "double"
|
||||
},
|
||||
|
||||
// Vue
|
||||
{
|
||||
files: ["**/*.vue"],
|
||||
rules: {
|
||||
"style/indent": "off"
|
||||
}
|
||||
rules: {
|
||||
curly: "off",
|
||||
"no-console": "off",
|
||||
"no-new-func": "off",
|
||||
"style/semi": ["error", "always"],
|
||||
"style/indent": ["error", "tab"],
|
||||
"style/quote-props": ["warn", "as-needed"],
|
||||
"style/comma-dangle": ["warn", "never"],
|
||||
"style/brace-style": ["warn", "1tbs"],
|
||||
"style/arrow-parens": ["error", "always"],
|
||||
"vue/block-order": ["error", {
|
||||
order: ["template", "script", "style"]
|
||||
}],
|
||||
"vue/script-indent": ["error", "tab", {
|
||||
baseIndent: 1
|
||||
}],
|
||||
"antfu/top-level-function": "off",
|
||||
"node/prefer-global/process": ["off"]
|
||||
}
|
||||
)
|
||||
)
|
||||
},
|
||||
|
||||
// Vue
|
||||
{
|
||||
files: ["**/*.vue"],
|
||||
rules: {
|
||||
"style/indent": "off"
|
||||
}
|
||||
},
|
||||
|
||||
nuxtConfig()
|
||||
);
|
||||
|
@@ -56,11 +56,13 @@ export default defineNuxtConfig({
|
||||
envPrefix: ["VITE_", "TAURI_"],
|
||||
server: {
|
||||
strictPort: true,
|
||||
hmr: mobile ? {
|
||||
protocol: "ws",
|
||||
host: await internalIpV4(),
|
||||
port: 3001,
|
||||
} : undefined,
|
||||
hmr: mobile
|
||||
? {
|
||||
protocol: "ws",
|
||||
host: await internalIpV4(),
|
||||
port: 3001
|
||||
}
|
||||
: undefined,
|
||||
watch: {
|
||||
ignored: ["**/src-tauri/**"]
|
||||
}
|
||||
@@ -81,8 +83,9 @@ export default defineNuxtConfig({
|
||||
routes: ["/"]
|
||||
}
|
||||
},
|
||||
// sourcemap: {
|
||||
// server: true,
|
||||
// client: false
|
||||
// }
|
||||
eslint: {
|
||||
config: {
|
||||
standalone: false
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@@ -2,20 +2,25 @@
|
||||
name = "nuxtor"
|
||||
version = "1.0.0"
|
||||
description = "Starter template for Nuxt 3 with Tauri"
|
||||
authors = ["NicolaSpadari"]
|
||||
authors = [ "NicolaSpadari" ]
|
||||
license = "MIT"
|
||||
repository = "https://github.com/NicolaSpadari/nuxtor"
|
||||
edition = "2021"
|
||||
|
||||
[lib]
|
||||
name = "nuxtor_lib"
|
||||
crate-type = ["staticlib", "cdylib", "rlib", "lib"]
|
||||
crate-type = [
|
||||
"staticlib",
|
||||
"cdylib",
|
||||
"rlib",
|
||||
"lib"
|
||||
]
|
||||
|
||||
[build-dependencies]
|
||||
tauri-build = { version = "2.0.0-beta", features = [] }
|
||||
|
||||
[dependencies]
|
||||
tauri = { version = "2.0.0-beta", features = ["tray-icon"] }
|
||||
tauri = { version = "2.0.0-beta", features = [ "tray-icon" ] }
|
||||
tauri-plugin-shell = "2.0.0-beta"
|
||||
serde = { version = "1", features = ["derive"] }
|
||||
serde = { version = "1", features = [ "derive" ] }
|
||||
serde_json = "1"
|
||||
|
File diff suppressed because one or more lines are too long
@@ -1 +1,34 @@
|
||||
{"main":{"identifier":"main","description":"Capabilities for the main window","local":true,"windows":["main"],"permissions":["path:default","event:default","window:default","app:default","resources:default","menu:default",{"identifier":"shell:allow-execute","allow":[{"args":["-c",{"validator":"\\S+"}],"cmd":"sh","name":"exec-sh","sidecar":false}]}]}}
|
||||
{
|
||||
"main": {
|
||||
"identifier": "main",
|
||||
"description": "Capabilities for the main window",
|
||||
"local": true,
|
||||
"windows": [
|
||||
"main"
|
||||
],
|
||||
"permissions": [
|
||||
"path:default",
|
||||
"event:default",
|
||||
"window:default",
|
||||
"app:default",
|
||||
"resources:default",
|
||||
"menu:default",
|
||||
{
|
||||
"identifier": "shell:allow-execute",
|
||||
"allow": [
|
||||
{
|
||||
"args": [
|
||||
"-c",
|
||||
{
|
||||
"validator": "\\S+"
|
||||
}
|
||||
],
|
||||
"cmd": "sh",
|
||||
"name": "exec-sh",
|
||||
"sidecar": false
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,56 +1,56 @@
|
||||
{
|
||||
"bundle": {
|
||||
"active": true,
|
||||
"targets": "all",
|
||||
"windows": {
|
||||
"certificateThumbprint": null,
|
||||
"digestAlgorithm": "sha256",
|
||||
"timestampUrl": ""
|
||||
},
|
||||
"icon": [
|
||||
"icons/32x32.png",
|
||||
"icons/128x128.png",
|
||||
"icons/128x128@2x.png",
|
||||
"icons/icon.icns",
|
||||
"icons/icon.ico"
|
||||
],
|
||||
"resources": [],
|
||||
"externalBin": [],
|
||||
"copyright": "",
|
||||
"category": "DeveloperTool",
|
||||
"shortDescription": "",
|
||||
"longDescription": "",
|
||||
"macOS": {},
|
||||
"linux": {
|
||||
"deb": {}
|
||||
}
|
||||
},
|
||||
"build": {
|
||||
"beforeBuildCommand": "pnpm generate",
|
||||
"frontendDist": "../dist",
|
||||
"beforeDevCommand": "pnpm dev",
|
||||
"devUrl": "http://localhost:3000"
|
||||
},
|
||||
"productName": "nuxtor",
|
||||
"version": "1.0.0",
|
||||
"identifier": "com.nicolaspadari.nuxtor",
|
||||
"plugins": {},
|
||||
"app": {
|
||||
"windows": [
|
||||
{
|
||||
"title": "Nuxtor",
|
||||
"width": 1920,
|
||||
"height": 1080,
|
||||
"resizable": true,
|
||||
"fullscreen": false
|
||||
}
|
||||
],
|
||||
"security": {
|
||||
"csp": null
|
||||
},
|
||||
"trayIcon": {
|
||||
"iconPath": "./icons/icon.png",
|
||||
"iconAsTemplate": true
|
||||
}
|
||||
}
|
||||
"bundle": {
|
||||
"active": true,
|
||||
"targets": "all",
|
||||
"windows": {
|
||||
"certificateThumbprint": null,
|
||||
"digestAlgorithm": "sha256",
|
||||
"timestampUrl": ""
|
||||
},
|
||||
"icon": [
|
||||
"icons/32x32.png",
|
||||
"icons/128x128.png",
|
||||
"icons/128x128@2x.png",
|
||||
"icons/icon.icns",
|
||||
"icons/icon.ico"
|
||||
],
|
||||
"resources": [],
|
||||
"externalBin": [],
|
||||
"copyright": "",
|
||||
"category": "DeveloperTool",
|
||||
"shortDescription": "",
|
||||
"longDescription": "",
|
||||
"macOS": {},
|
||||
"linux": {
|
||||
"deb": {}
|
||||
}
|
||||
},
|
||||
"build": {
|
||||
"beforeBuildCommand": "pnpm generate",
|
||||
"frontendDist": "../dist",
|
||||
"beforeDevCommand": "pnpm dev",
|
||||
"devUrl": "http://localhost:3000"
|
||||
},
|
||||
"productName": "nuxtor",
|
||||
"version": "1.0.0",
|
||||
"identifier": "com.nicolaspadari.nuxtor",
|
||||
"plugins": {},
|
||||
"app": {
|
||||
"windows": [
|
||||
{
|
||||
"title": "Nuxtor",
|
||||
"width": 1920,
|
||||
"height": 1080,
|
||||
"resizable": true,
|
||||
"fullscreen": false
|
||||
}
|
||||
],
|
||||
"security": {
|
||||
"csp": null
|
||||
},
|
||||
"trayIcon": {
|
||||
"iconPath": "./icons/icon.png",
|
||||
"iconAsTemplate": true
|
||||
}
|
||||
}
|
||||
}
|
@@ -5,7 +5,7 @@
|
||||
</template>
|
||||
|
||||
<style lang="scss">
|
||||
html {
|
||||
html {
|
||||
-webkit-tap-highlight-color: transparent;
|
||||
scroll-behavior: smooth;
|
||||
@apply min-h-screen;
|
||||
|
@@ -9,8 +9,8 @@
|
||||
<script lang="ts" setup>
|
||||
const version = await getTauriVersion();
|
||||
|
||||
const result = await Command.create('exec-sh', [
|
||||
'-c',
|
||||
"echo 'Hello World!'",
|
||||
const result = await Command.create("exec-sh", [
|
||||
"-c",
|
||||
"echo 'Hello World!'"
|
||||
]).execute();
|
||||
</script>
|
Reference in New Issue
Block a user