shinkansen-relay 1.0.314 → 1.0.316

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,72 @@
1
+ import globals from 'globals'
2
+ import standard from '@sequencemedia/eslint-config-standard/configs/recommended/merge'
3
+ import typescript from '@sequencemedia/eslint-config-typescript/configs/recommended/merge'
4
+
5
+ export default [
6
+ /**
7
+ * Standard config
8
+ */
9
+ standard({
10
+ files: [
11
+ '**/*.{mjs,cjs,mts,cts}'
12
+ ],
13
+ ignores: [
14
+ 'src',
15
+ 'test'
16
+ ],
17
+ languageOptions: {
18
+ globals: {
19
+ ...globals.node
20
+ }
21
+ }
22
+ }),
23
+ standard({
24
+ files: [
25
+ 'src/**/*.{mjs,cjs,mts,cts}'
26
+ ],
27
+ languageOptions: {
28
+ globals: {
29
+ ...globals.browser
30
+ }
31
+ }
32
+ }),
33
+ standard({
34
+ files: [
35
+ 'test/**/*.{mjs,cjs,mts,cts}'
36
+ ],
37
+ languageOptions: {
38
+ globals: {
39
+ ...globals.mocha
40
+ }
41
+ }
42
+ }),
43
+ /**
44
+ * TypeScript config
45
+ */
46
+ typescript({
47
+ files: [
48
+ '**/*.{mts,cts}'
49
+ ],
50
+ ignores: [
51
+ 'src',
52
+ 'test'
53
+ ],
54
+ languageOptions: {
55
+ globals: {
56
+ ...globals.node
57
+ }
58
+ }
59
+ }),
60
+ typescript({
61
+ files: [
62
+ 'src/**/*.{mts,cts}',
63
+ 'test/**/*.{mts,cts}'
64
+ ],
65
+ languageOptions: {
66
+ globals: {
67
+ ...globals.browser,
68
+ RelayTypes: 'readonly'
69
+ }
70
+ }
71
+ })
72
+ ]
package/index.d.mts ADDED
@@ -0,0 +1,12 @@
1
+ declare global {
2
+ namespace RelayTypes {
3
+ export interface RelayType {
4
+ SIGNAL: string
5
+ SERVICE: string
6
+ }
7
+
8
+ export type StateType = Record<PropertyKey, boolean>
9
+ }
10
+ }
11
+
12
+ export {}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shinkansen-relay",
3
- "version": "1.0.314",
3
+ "version": "1.0.316",
4
4
  "description": "Shinkansen Relay",
5
5
  "keywords": [
6
6
  "Shinkansen",
@@ -11,7 +11,7 @@
11
11
  ],
12
12
  "main": "./src/index.cjs",
13
13
  "type": "module",
14
- "types": "./src/index.d.mts",
14
+ "types": "./index.d.mts",
15
15
  "author": {
16
16
  "name": "Jonathan Perry for Modern Poacher Limited",
17
17
  "email": "modernpoacher@modernpoacher.com",
@@ -26,7 +26,7 @@
26
26
  "url": "git+ssh://git@github.com/modernpoacher/shinkansen-relay.git"
27
27
  },
28
28
  "scripts": {
29
- "lint": "eslint . --ext .mjs,.cjs,.mts,.cts",
29
+ "lint": "eslint",
30
30
  "lint:fix": "npm run lint -- --fix",
31
31
  "nvm": "bash nvm.sh",
32
32
  "prelint": "npm run nvm",
@@ -39,19 +39,20 @@
39
39
  },
40
40
  "devDependencies": {
41
41
  "@babel/core": "^7.26.0",
42
- "@babel/eslint-parser": "^7.25.9",
42
+ "@babel/eslint-parser": "^7.26.5",
43
43
  "@babel/preset-env": "^7.26.0",
44
44
  "@babel/register": "^7.25.9",
45
- "@typescript-eslint/eslint-plugin": "7.18.0",
46
- "@typescript-eslint/parser": "7.18.0",
45
+ "@sequencemedia/eslint-config-standard": "^0.2.10",
46
+ "@sequencemedia/eslint-config-typescript": "^0.1.15",
47
+ "@typescript-eslint/eslint-plugin": "^8.19.1",
48
+ "@typescript-eslint/parser": "^8.19.1",
47
49
  "babel-plugin-module-resolver": "^5.0.2",
48
50
  "chai": "^5.1.2",
49
51
  "core-js": "^3.40.0",
50
52
  "cross-env": "^7.0.3",
51
- "eslint": "8.57.1",
52
- "eslint-config-love": "47.0.0",
53
- "eslint-config-standard": "^17.1.0",
53
+ "eslint": "^9.17.0",
54
54
  "eslint-import-resolver-babel-module": "^5.3.2",
55
+ "globals": "^15.14.0",
55
56
  "husky": "^9.1.7",
56
57
  "mocha": "^11.0.1",
57
58
  "shinkansen-signals": "1.1.187"
package/src/index.d.mts CHANGED
@@ -1,12 +1,3 @@
1
- declare namespace RelayTypes {
2
- export interface RelayType {
3
- SIGNAL: string
4
- SERVICE: string
5
- }
6
-
7
- export type StateType = Record<PropertyKey, boolean>
8
- }
9
-
10
1
  declare module '#relay' {
11
2
  export { default as Relay } from '#relay/relay'
12
3
  }
@@ -1,5 +1,5 @@
1
1
  declare module '#relay/relay' {
2
- export default class Relay {
2
+ export default class Relay { // eslint-disable-line @typescript-eslint/no-extraneous-class -- Static class
3
3
  static initiate (relay: { was: Record<PropertyKey, string>, now: Record<PropertyKey, string> }): RelayTypes.StateType
4
4
 
5
5
  static regulate (state: RelayTypes.StateType): RelayTypes.RelayType
package/tsconfig.json CHANGED
@@ -25,6 +25,7 @@
25
25
  }
26
26
  },
27
27
  "include": [
28
- "src/**/*"
28
+ ".",
29
+ "src/**/*",
29
30
  ]
30
31
  }