Skip to content

Commit

Permalink
Merge pull request #38 from k-urtica/feat/remove-prettier
Browse files Browse the repository at this point in the history
Feat/remove prettier
  • Loading branch information
k-urtica authored Jul 10, 2024
2 parents 7c533de + 8c58c56 commit 0544e48
Show file tree
Hide file tree
Showing 22 changed files with 1,303 additions and 342 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@ jobs:
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: Setup pnpm cache
uses: actions/cache@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install

Expand Down
6 changes: 0 additions & 6 deletions .prettierignore

This file was deleted.

9 changes: 0 additions & 9 deletions .prettierrc

This file was deleted.

46 changes: 46 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"prettier.enable": false,
"editor.formatOnSave": false,

"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit",
"source.organizeImports": "never"
},

"eslint.rules.customizations": [
{ "rule": "style/*", "severity": "off" },
{ "rule": "format/*", "severity": "off" },
{ "rule": "*-indent", "severity": "off" },
{ "rule": "*-spacing", "severity": "off" },
{ "rule": "*-spaces", "severity": "off" },
{ "rule": "*-order", "severity": "off" },
{ "rule": "*-dangle", "severity": "off" },
{ "rule": "*-newline", "severity": "off" },
{ "rule": "*quotes", "severity": "off" },
{ "rule": "*semi", "severity": "off" }
],

// Enable eslint for all supported languages
"eslint.validate": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact",
"vue",
"html",
"markdown",
"json",
"jsonc",
"yaml",
"toml",
"xml",
"gql",
"graphql",
"astro",
"css",
"less",
"scss",
"pcss",
"postcss"
]
}
37 changes: 23 additions & 14 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,17 +1,26 @@
import eslintConfigPrettier from 'eslint-config-prettier';
// @ts-check
import antfu from '@antfu/eslint-config';

import tailwind from 'eslint-plugin-tailwindcss';
import withNuxt from './.nuxt/eslint.config.mjs';

export default withNuxt({
rules: {
'vue/define-macros-order': [
'warn',
{
order: ['defineOptions', 'defineModel', 'defineProps', 'defineEmits', 'defineSlots'],
},
],
'vue/require-default-prop': 'off',
export default withNuxt(
antfu({
stylistic: {
semi: true,
},
rules: {
'vue/define-macros-order': [
'warn',
{
order: ['defineOptions', 'defineModel', 'defineProps', 'defineEmits', 'defineSlots'],
},
],
},

...eslintConfigPrettier.rules,
},
});
}),
[...tailwind.configs['flat/recommended'], {
rules: {
'tailwindcss/no-custom-classname': 'off',
},
}],
);
10 changes: 8 additions & 2 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const siteTitle = 'K - Web Developer';
const description =
"Hey there! I'm K, a web developer who loves programming and traveling. This is my portfolio site.";
const description
= 'Hey there! I\'m K, a web developer who loves programming and traveling. This is my portfolio site.';

export default defineNuxtConfig({
srcDir: 'src/',
Expand Down Expand Up @@ -45,6 +45,12 @@ export default defineNuxtConfig({
sitemaps: false,
},

eslint: {
config: {
standalone: false,
},
},

runtimeConfig: {
public: {
siteUrl: 'https://k-urtica.github.io',
Expand Down
13 changes: 6 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
{
"name": "k-urtica.github.io",
"version": "1.0.0",
"private": true,
"description": "K portfolio site.",
"author": "K",
"private": true,
"scripts": {
"dev": "nuxt dev",
"build": "nuxt build",
"preview": "nuxt preview",
"generate": "nuxt generate",
"analyze": "nuxt analyze",
"lint": "eslint . --max-warnings=0",
"lint-fix": "pnpm prettier-fix && eslint . --fix",
"lint": "eslint .",
"lint-fix": "eslint . --fix",
"prettier-check": "prettier --check src/",
"prettier-fix": "prettier --write src/",
"postinstall": "nuxt prepare"
Expand All @@ -20,14 +20,13 @@
"twemoji": "^14.0.2"
},
"devDependencies": {
"@antfu/eslint-config": "^2.22.0",
"@mdi/js": "^7.4.47",
"@nuxt/eslint": "^0.3.13",
"@nuxtjs/sitemap": "^5.2.2",
"@nuxtjs/tailwindcss": "^6.12.0",
"eslint": "^9.6.0",
"eslint-config-prettier": "^9.1.0",
"nuxt": "^3.12.2",
"prettier": "^3.3.2",
"prettier-plugin-tailwindcss": "^0.6.5"
"eslint-plugin-tailwindcss": "^3.17.4",
"nuxt": "^3.12.2"
}
}
Loading

0 comments on commit 0544e48

Please sign in to comment.