svelte-command 1.1.20 → 1.1.23

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.
package/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  [![Svelte v3](https://img.shields.io/badge/svelte-v3-orange.svg)](https://svelte.dev)
2
2
  [![npm](https://img.shields.io/npm/v/svelte-command.svg)](https://www.npmjs.com/package/svelte-command)
3
3
  [![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)
4
- [![minified size](https://badgen.net/bundlephobia/min/svelte-command)](https://bundlephobia.com/result?p=svelte-command)
4
+ [![Open Bundle](https://bundlejs.com/badge-light.svg)](https://bundlejs.com/?q=svelte-command)
5
5
  [![downloads](http://img.shields.io/npm/dm/svelte-command.svg?style=flat-square)](https://npmjs.org/package/svelte-command)
6
6
  [![GitHub Issues](https://img.shields.io/github/issues/arlac77/svelte-command.svg?style=flat-square)](https://github.com/arlac77/svelte-command/issues)
7
7
  [![Build Status](https://img.shields.io/endpoint.svg?url=https%3A%2F%2Factions-badge.atrox.dev%2Farlac77%2Fsvelte-command%2Fbadge\&style=flat)](https://actions-badge.atrox.dev/arlac77/svelte-command/goto)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "svelte-command",
3
- "version": "1.1.20",
3
+ "version": "1.1.23",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -24,7 +24,7 @@
24
24
  "prepare": "vite build",
25
25
  "start": "vite",
26
26
  "test": "npm run test:ava && npm run test:cafe",
27
- "test:cafe": "testcafe $BROWSER:headless tests/cafe/*.js -s build/test --page-request-timeout 9000 --app-init-delay 3000 --app vite",
27
+ "test:cafe": "testcafe $BROWSER:headless tests/cafe/*.js -s build/test --page-request-timeout 3000 --app-init-delay 3000 --app \"vite preview\"",
28
28
  "test:ava": "ava --timeout 2m tests/*.mjs",
29
29
  "docs": "documentation readme --section=API ./src/**/*.mjs",
30
30
  "lint": "npm run lint:docs",
@@ -36,17 +36,17 @@
36
36
  "@semantic-release/exec": "^6.0.3",
37
37
  "@semantic-release/release-notes-generator": "^10.0.3",
38
38
  "@sveltejs/vite-plugin-svelte": "^1.0.1",
39
- "ava": "^4.3.0",
39
+ "ava": "^4.3.1",
40
40
  "documentation": "^13.2.5",
41
- "mf-styling": "^1.2.26",
42
- "npm-pkgbuild": "^10.9.2",
41
+ "mf-styling": "^1.2.45",
42
+ "npm-pkgbuild": "^10.14.8",
43
43
  "semantic-release": "^19.0.3",
44
- "svelte": "^3.48.0",
45
- "testcafe": "^1.19.0",
46
- "vite": "^3.0.0"
44
+ "svelte": "^3.49.0",
45
+ "testcafe": "^1.20.1",
46
+ "vite": "^3.0.8"
47
47
  },
48
48
  "optionalDependencies": {
49
- "mf-hosting": "^1.7.0"
49
+ "mf-hosting": "^1.7.2"
50
50
  },
51
51
  "repository": {
52
52
  "type": "git",
@@ -61,8 +61,8 @@
61
61
  "${install.dir}": "build/",
62
62
  "${nginx.sites.dir}${name}.conf": "pkg/nginx.conf"
63
63
  },
64
- "http.base.path": "/examples",
65
- "groups": "examples"
64
+ "groups": "examples",
65
+ "description": "example showing ${name} features in action"
66
66
  },
67
67
  "release": {
68
68
  "plugins": [
@@ -84,7 +84,7 @@
84
84
  "arlac77/template-ava",
85
85
  "arlac77/template-cloudflare",
86
86
  "arlac77/template-pacman",
87
- "arlac77/template-svelte-component#next"
87
+ "arlac77/template-svelte-component"
88
88
  ]
89
89
  }
90
90
  }
package/src/command.mjs CHANGED
@@ -1,4 +1,7 @@
1
1
  export class BasicCommand {
2
+
3
+ subscriptions = new Set();
4
+
2
5
  constructor(start, properties, options = {}) {
3
6
  if (options.timeout !== undefined) {
4
7
  properties.timeout = { value: options.timeout };
@@ -7,7 +10,6 @@ export class BasicCommand {
7
10
  Object.defineProperties(this, {
8
11
  _start: { value: start },
9
12
  _cancel: { value: options.cancel || (() => {}) },
10
- subscriptions: { value: new Set() },
11
13
  ...properties
12
14
  });
13
15
 
package/vite.config.js DELETED
@@ -1,43 +0,0 @@
1
- import { svelte } from "@sveltejs/vite-plugin-svelte";
2
- import { defineConfig } from "vite";
3
-
4
- export default defineConfig(async ({ command, mode }) => {
5
- const { extractFromPackage } = await import(
6
- new URL("node_modules/npm-pkgbuild/src/module.mjs", import.meta.url)
7
- );
8
- const res = extractFromPackage({
9
- dir: new URL("./", import.meta.url).pathname
10
- });
11
- const first = await res.next();
12
- const pkg = first.value;
13
- const properties = pkg.properties;
14
- const base = properties["http.path"] + "/";
15
- const production = mode === "production";
16
-
17
- process.env["VITE_NAME"] = properties.name;
18
- process.env["VITE_DESCRIPTION"] = properties.description;
19
- process.env["VITE_VERSION"] = properties.version;
20
-
21
- const open = process.env.CI ? {} : { open: base };
22
-
23
- return {
24
- base,
25
- root: "tests/app/src",
26
- worker: { format: "es" },
27
- plugins: [
28
- svelte({
29
- compilerOptions: {
30
- dev: !production
31
- }
32
- })
33
- ],
34
- server: { host: true, ...open },
35
- build: {
36
- outDir: "../../../build",
37
- target: "esnext",
38
- emptyOutDir: true,
39
- minify: production,
40
- sourcemap: true
41
- }
42
- };
43
- });