Skip to content

Commit

Permalink
Merge pull request #1190 from pjkaufman/master
Browse files Browse the repository at this point in the history
Remove JS Styling, Minify CSS, Speed Up Settings Page Loading, Remove Use of `innerHTML`, and Remove Default Hotkey
  • Loading branch information
pjkaufman authored Oct 11, 2024
2 parents ec657ea + 84de78e commit e27f566
Show file tree
Hide file tree
Showing 30 changed files with 2,165 additions and 189 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ main.js
translation-helper.js
.eslintrc.js
babel.config.js
postss.config.js
7 changes: 4 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,16 @@ jobs:
with:
node-version: "18.x"

- name: Build plugin
- name: Build plugin and minfy css
run: |
npm ci
npm run build
npm run minify-css
- name: Create Manual Install Zip
run: |
mkdir ${{ env.PLUGIN_NAME }}
cp main.js manifest.json src/styles.css src/utils/default-misspellings.md ${{ env.PLUGIN_NAME }}
cp main.js manifest.json styles.css src/utils/default-misspellings.md ${{ env.PLUGIN_NAME }}
zip -r ${{ env.PLUGIN_NAME }}.zip ${{ env.PLUGIN_NAME }}
- name: Create release
Expand All @@ -40,4 +41,4 @@ jobs:
gh release create "$tag" \
--title="$tag" \
--draft \
main.js manifest.json src/styles.css ${{ env.PLUGIN_NAME }}.zip
main.js manifest.json styles.css ${{ env.PLUGIN_NAME }}.zip
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ test-vault/.obsidian/plugins/table-editor-obsidian/*
# occasional bug fix test
main.zip

# ignore generated files
main.js
styles.css

yarn.lock

.DS_Store
Expand Down
6 changes: 3 additions & 3 deletions esbuild.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ const mockedPlugins = [replace({
// remove the use of obsidian in the options to allow for docs.js to run
'import {Setting} from \'obsidian\';': '',
// remove the use of obsidian in settings helper to allow for docs.js to run
'import {App, Component, MarkdownRenderer} from \'obsidian\';': '',
'import {App, MarkdownRenderer} from \'obsidian\';': '',
// remove the use of obsidian in the auto-correct files picker to allow for docs.js to run
'import {Setting, Component, App, TFile, normalizePath, ExtraButtonComponent} from \'obsidian\';': '',
'import {Setting, App, TFile, normalizePath, ExtraButtonComponent} from \'obsidian\';': '',
// remove the use of obsidian in add custom row to allow for docs.js to run
'import {App, Component, Setting} from \'obsidian\';': '',
'import {App, Setting} from \'obsidian\';': '',
// remove the use of obsidian in suggest to allow for docs.js to run
'import {App, ISuggestOwner, Scope} from \'obsidian\';': '',
// remove the use of obsidian in md file suggester to allow for docs.js to run
Expand Down
Loading

0 comments on commit e27f566

Please sign in to comment.