@humanspeak/svelte-markdown 0.5.3 → 0.5.4

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
@@ -10,18 +10,10 @@ You can install it with
10
10
  npm i -S @humanspeak/svelte-markdown
11
11
  ```
12
12
 
13
- If you use npm or if you prefer yarn
14
-
15
- ```console
16
- yarn add @humanspeak/svelte-markdown
17
- ```
18
-
19
- If you're using Sapper you might need to install it as a dev dependency.
20
-
21
13
  ## Usage
22
14
 
23
- ```html
24
- <script>
15
+ ```svelte
16
+ <script lang="ts">
25
17
  import SvelteMarkdown from '@humanspeak/svelte-markdown'
26
18
  const source = `
27
19
  # This is a header
@@ -42,6 +42,7 @@
42
42
  align={rest.align[i] || 'center'}
43
43
  {...rest}
44
44
  >
45
+ {rest.align[i]}
45
46
  <Parser tokens={headerItem.tokens} {renderers} />
46
47
  </renderers.tablecell>
47
48
  {/each}
@@ -53,7 +54,7 @@
53
54
  {#each row ?? [] as cells, i}
54
55
  <renderers.tablecell
55
56
  header={false}
56
- align={rest.align[i] || 'center'}
57
+ align={rest.align[i] ?? 'center'}
57
58
  {...rest}
58
59
  >
59
60
  <Parser tokens={cells.tokens} {renderers} />
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@humanspeak/svelte-markdown",
3
3
  "description": "A markdown renderer for Svelte",
4
- "version": "0.5.3",
4
+ "version": "0.5.4",
5
5
  "scripts": {
6
6
  "dev": "vite dev",
7
7
  "build": "vite build && npm run package",
@@ -19,14 +19,18 @@
19
19
  },
20
20
  "repository": {
21
21
  "type": "git",
22
- "url": "https://github.com/humanspeak/svelte-markdown.git"
22
+ "url": "git+https://github.com/humanspeak/svelte-markdown.git"
23
23
  },
24
24
  "author": "Humanspeak, Inc.",
25
25
  "license": "MIT",
26
26
  "bugs": {
27
27
  "url": "https://github.com/humanspeak/svelte-markdown/issues"
28
28
  },
29
- "homepage": "https://github.com/humanspeak/svelte-markdown",
29
+ "tags": [
30
+ "svelte",
31
+ "markdown"
32
+ ],
33
+ "homepage": "sveltemarkdown.com",
30
34
  "files": [
31
35
  "dist",
32
36
  "!dist/**/*.test.*",
@@ -48,11 +52,13 @@
48
52
  "svelte": "^5.0.0"
49
53
  },
50
54
  "dependencies": {
55
+ "github-slugger": "^2.0.0",
51
56
  "marked": "^14.1.3"
52
57
  },
53
58
  "devDependencies": {
54
59
  "@eslint/eslintrc": "^3.1.0",
55
60
  "@eslint/js": "^9.13.0",
61
+ "@sveltejs/adapter-auto": "^3.3.1",
56
62
  "@sveltejs/kit": "^2.7.3",
57
63
  "@sveltejs/package": "^2.3.7",
58
64
  "@sveltejs/vite-plugin-svelte": "^4.0.0",
@@ -66,7 +72,6 @@
66
72
  "eslint": "^9.13.0",
67
73
  "eslint-config-prettier": "^9.1.0",
68
74
  "eslint-plugin-svelte": "^2.46.0",
69
- "github-slugger": "^2.0.0",
70
75
  "globals": "^15.11.0",
71
76
  "jsdom": "^25.0.1",
72
77
  "prettier": "^3.3.3",
@@ -77,7 +82,6 @@
77
82
  "svelte": "^5.1.4",
78
83
  "svelte-check": "^4.0.5",
79
84
  "typescript": "^5.6.3",
80
- "@sveltejs/adapter-auto": "^3.3.1",
81
85
  "vite": "^5.4.10",
82
86
  "vitest": "^2.1.4"
83
87
  },