Skip to content

Commit

Permalink
Add lint and reformat, refactor for cr
Browse files Browse the repository at this point in the history
  • Loading branch information
aaachen committed Apr 11, 2024
1 parent f95d25b commit b19a2f6
Show file tree
Hide file tree
Showing 18 changed files with 1,466 additions and 1,252 deletions.
4 changes: 2 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
npm node_modules
build
node_modules
build
40 changes: 21 additions & 19 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
{
"root": true,
"parser": "@typescript-eslint/parser",
"env": { "node": true },
"plugins": ["@typescript-eslint"],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"parserOptions": {
"sourceType": "module"
},
"rules": {
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": ["error", { "args": "none" }],
"@typescript-eslint/ban-ts-comment": "off",
"no-prototype-builtins": "off",
"@typescript-eslint/no-empty-function": "off"
}
"root": true,
"parser": "@typescript-eslint/parser",
"env": { "node": true },
"plugins": ["@typescript-eslint"],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended"
],
"parserOptions": {
"project": "./tsconfig.json"
},
"rules": {
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": ["error", { "args": "none" }],
"@typescript-eslint/ban-ts-comment": "off",
"no-prototype-builtins": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-extra-semi": "off",
"semi": [2, "never"]
}
}
18 changes: 3 additions & 15 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
{
"arrowParens": "avoid",
"bracketSpacing": true,
"htmlWhitespaceSensitivity": "css",
"insertPragma": false,
"jsxBracketSameLine": false,
"jsxSingleQuote": true,
"printWidth": 80,
"proseWrap": "always",
"quoteProps": "as-needed",
"requirePragma": false,
"semi": false,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "all",
"useTabs": false
"semi": false,
"singleQuote": true,
"endOfLine": "auto"
}
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 aaachen
Copyright (c) 2024 aaachen

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
6 changes: 3 additions & 3 deletions main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ export default class IMDb extends Plugin {
await this.loadSettings()

// This creates an icon in the left ribbon.
this.addRibbonIcon('star', 'IMDb Sync', (evt: MouseEvent) => {
this.addRibbonIcon('star', 'Sync', (evt: MouseEvent) => {
this.updateLibrary()
})

// This adds a simple command that can be triggered anywhere
this.addCommand({
id: 'imdb-sync',
name: 'IMDb Sync',
id: 'sync',
name: 'Sync',
callback: () => {
this.updateLibrary()
},
Expand Down
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"name": "IMDb",
"version": "1.0.0",
"minAppVersion": "0.12.0",
"description": "Connect Obsidian to your IMDb.",
"description": "Sync your IMDb list",
"author": "Andrew Chen",
"authorUrl": "https://github.com/aaachen",
"isDesktopOnly": true
Expand Down
Loading

0 comments on commit b19a2f6

Please sign in to comment.