Compare commits

...

4 commits

Author SHA1 Message Date
Kristjan ESPERANTO
563c47f1f6
chore: release v1.1.1 2025-05-18 10:37:28 +02:00
Kristjan ESPERANTO
a9981b8852
chore: use node --run instead of npm run to run scripts 2025-05-18 10:26:32 +02:00
Kristjan ESPERANTO
516e78ceb9
chore: update devDependencies 2025-05-18 10:26:17 +02:00
Kristjan ESPERANTO
5b6abc66e9
chore: review ESLint config and add markdown linting 2025-05-18 10:24:15 +02:00
7 changed files with 1245 additions and 94 deletions

View file

@ -26,7 +26,7 @@ have aptly described your issue in words, feel free to ignore/delete this sectio
**Please fill out the following information;**
- Node version: [This can be obtained by running `node -v` in your terminal]
- Have you updated to the latest MagicMirror core? [yes/no]
- Have you updated to the latest MagicMirror core? (yes/no)
- Please post the relevant part of your config file here:
```json
@ -35,7 +35,7 @@ have aptly described your issue in words, feel free to ignore/delete this sectio
- Please post any errors you see about MMM-pages in the console (Hit F12 > Console when the MagicMirror window is focused), or write **None** if there aren't any:
```
```bash
(Paste the error here)
```

View file

@ -23,4 +23,4 @@ jobs:
- name: Install dependencies
run: npm ci
- name: Check linting
run: npm run lint
run: node --run lint

View file

@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.1.1](https://github.com/edward-shen/MMM-pages/compare/v1.1.0...v1.1.1) - 2025-03-26 - Maintenance Release
### Changed
- chore: review ESLint config and add markdown linting
- chore: update devDependencies
- chore: use `node --run` instead of `npm run` to run scripts
## [1.1.0](https://github.com/edward-shen/MMM-pages/compare/v1.0.1...v1.1.0) - 2025-03-25 - Feature Release
### Added

View file

@ -285,8 +285,8 @@ See also FAQ below.
If you want to contribute to this project, pleases use the following commands to maintain code quality:
- `npm install` - Install development dependencies for linting.
- `npm run lint` - Run linting checks.
- `npm run lint:fix` - Fix linting issues. Please run this before committing.
- `node --run lint` - Run linting checks.
- `node --run lint:fix` - Fix linting issues. Please run this before committing.
[mm]: https://github.com/MagicMirrorOrg/MagicMirror
[page indicator]: https://github.com/edward-shen/MMM-page-indicator

View file

@ -1,13 +1,14 @@
import eslintPluginJs from '@eslint/js';
import eslintPluginStylistic from '@stylistic/eslint-plugin';
import { defineConfig } from 'eslint/config';
import globals from 'globals';
import js from '@eslint/js';
import markdown from '@eslint/markdown';
import stylistic from '@stylistic/eslint-plugin';
const config = [
eslintPluginJs.configs.recommended,
eslintPluginStylistic.configs.recommended,
export default defineConfig([
{
files: ['**/*.js', '**/*.mjs'],
files: ['**/*.js'],
languageOptions: {
ecmaVersion: 'latest',
globals: {
...globals.browser,
Log: 'readonly',
@ -16,14 +17,30 @@ const config = [
module: 'readonly',
},
},
plugins: { js, stylistic },
extends: ['js/recommended', 'stylistic/recommended'],
rules: {
'@stylistic/brace-style': ['error', '1tbs', { allowSingleLine: true }],
'@stylistic/comma-dangle': ['error', 'only-multiline'],
'@stylistic/max-statements-per-line': ['error', { max: 2 }],
'@stylistic/semi': ['error', 'always'],
'object-shorthand': ['error', 'always']
}
},
{
files: ['**/*.mjs'],
languageOptions: {
ecmaVersion: 'latest',
globals: {
...globals.node,
},
sourceType: 'module'
},
}
];
export default config;
plugins: { js, stylistic },
extends: ['js/recommended', 'stylistic/recommended'],
rules: {
'@stylistic/comma-dangle': ['error', 'only-multiline'],
'@stylistic/semi': ['error', 'always'],
}
},
{ files: ['**/*.md'], plugins: { markdown }, language: 'markdown/gfm', extends: ['markdown/recommended'] },
]);

1271
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -1,6 +1,6 @@
{
"name": "mmm-pages",
"version": "1.1.0",
"version": "1.1.1",
"description": "Add pages to your MagicMirror².",
"main": "MMM-pages.js",
"repository": {
@ -21,12 +21,13 @@
"scripts": {
"lint": "eslint",
"lint:fix": "eslint --fix",
"test": "npm run lint"
"test": "node --run lint"
},
"devDependencies": {
"@eslint/js": "^9.23.0",
"@eslint/js": "^9.27.0",
"@eslint/markdown": "^6.4.0",
"@stylistic/eslint-plugin": "^4.2.0",
"eslint": "^9.23.0",
"globals": "^16.0.0"
"eslint": "^9.27.0",
"globals": "^16.1.0"
}
}