diff --git a/eslint.config.js b/eslint.config.js index 6cc0d5cd..33631394 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -1,18 +1,18 @@ // @ts-check -const eslint = require('@eslint/js'); -const tseslint = require('typescript-eslint'); -const angular = require('angular-eslint'); +import js from '@eslint/js'; +import tsEslint from 'typescript-eslint'; +import ngEslint from 'angular-eslint'; -module.exports = tseslint.config( +export default tsEslint.config( { files: ['**/*.ts'], extends: [ - eslint.configs.recommended, - ...tseslint.configs.recommended, - ...tseslint.configs.stylistic, - ...angular.configs.tsRecommended, + js.configs.recommended, + ...tsEslint.configs.recommended, + ...tsEslint.configs.stylistic, + ...ngEslint.configs.tsRecommended, ], - processor: angular.processInlineTemplates, + processor: ngEslint.processInlineTemplates, rules: { '@angular-eslint/directive-selector': [ 'error', @@ -34,7 +34,10 @@ module.exports = tseslint.config( }, { files: ['**/*.html'], - extends: [...angular.configs.templateRecommended, ...angular.configs.templateAccessibility], + extends: [ + ...ngEslint.configs.templateRecommended, + ...ngEslint.configs.templateAccessibility, + ], rules: { '@angular-eslint/template/label-has-associated-control': ['off'], '@angular-eslint/template/click-events-have-key-events': ['off'], diff --git a/public/assets/Kahla.icns b/native-assets/Kahla.icns similarity index 100% rename from public/assets/Kahla.icns rename to native-assets/Kahla.icns diff --git a/package.json b/package.json index ff2f545d..d8b33f6b 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,7 @@ "l2dy@macports.org" ], "license": "MIT", + "type": "module", "scripts": { "start": "yarn build:sw-base && ng serve", "build:sw-base": "tsc -p ./sw-base/", diff --git a/public/assets/.gitkeep b/public/assets/.gitkeep deleted file mode 100644 index e69de29b..00000000 diff --git a/workbox-config.js b/workbox-config.js index 4d588f7b..557d0866 100644 --- a/workbox-config.js +++ b/workbox-config.js @@ -1,11 +1,11 @@ module.exports = { globDirectory: './dist/browser', - globPatterns: ['**/*.{png,icns,js,ico,html,json,ttf,woff2,css}'], + globPatterns: ['**/*.{png,js,ico,html,json,woff2,css}'], swDest: 'dist/browser/sw.js', ignoreURLParametersMatching: [/^utm_/, /^fbclid$/], importScripts: ['./sw_notifications.js'], sourcemap: false, cleanupOutdatedCaches: true, navigateFallback: '/index.html', - navigateFallbackDenylist: [/^\/api\//], + navigateFallbackDenylist: [/^\/api\//, /^\/assets\//], };