You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+6-10Lines changed: 6 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ The repo depends on the latest plugin API (obsidian.d.ts) in TypeScript Definiti
7
7
8
8
This sample plugin demonstrates some of the basic functionality the plugin API can do.
9
9
- Adds a ribbon icon, which shows a Notice when clicked.
10
-
- Adds a command "Open Sample Modal" which opens a Modal.
10
+
- Adds a command "Open modal (simple)" which opens a Modal.
11
11
- Adds a plugin setting tab to the settings page.
12
12
- Registers a global click event and output 'click' to the console.
13
13
- Registers a global interval which logs 'setInterval' to the console.
@@ -55,15 +55,11 @@ Quick starting guide for new plugin devs:
55
55
56
56
- Copy over `main.js`, `styles.css`, `manifest.json` to your vault `VaultFolder/.obsidian/plugins/your-plugin-id/`.
57
57
58
-
## Improve code quality with eslint (optional)
58
+
## Improve code quality with eslint
59
59
-[ESLint](https://eslint.org/) is a tool that analyzes your code to quickly find problems. You can run ESLint against your plugin to find common bugs and ways to improve your code.
60
-
- To use eslint with this project, make sure to install eslint from terminal:
61
-
-`npm install -g eslint`
62
-
- To use eslint to analyze this project use this command:
63
-
-`eslint main.ts`
64
-
- eslint will then create a report with suggestions for code improvement by file and line number.
65
-
- If your source code is in a folder, such as `src`, you can use eslint with this command to analyze all files in that folder:
66
-
-`eslint ./src/`
60
+
- This project already has eslint preconfigured, you can invoke a check by running`npm run lint`
61
+
- Together with a custom eslint [plugin](https://github.com/eslint-plugin) for Obsidan specific code guidelines.
62
+
- A GitHub action is preconfigured to automatically lint every commit on all branches.
67
63
68
64
## Funding URL
69
65
@@ -91,4 +87,4 @@ If you have multiple URLs, you can also do:
0 commit comments