@sveltia/cms 0.8.0 → 0.8.2
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 +31 -30
- package/dist/sveltia-cms.js +132 -132
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
# Sveltia CMS
|
|
2
2
|
|
|
3
|
-
Sveltia CMS is a Git-based lightweight headless CMS under development as a
|
|
3
|
+
Sveltia CMS is a Git-based lightweight headless CMS under active development as a quick replacement for [Netlify/Decap CMS](https://decapcms.org/). You can use it with your favourite static site generator like SvelteKit, Eleventy, Next.js and Hugo to manage content as static files in a Git repository. The open source alternative to Netlify/Decap CMS is now in public beta — with more features to come.
|
|
4
4
|
|
|
5
|
-
<br>
|
|
6
6
|
|
|
7
|
-
<br>
|
|
8
8
|
|
|
9
|
-
<br>
|
|
10
10
|
|
|
11
|
-
<br>
|
|
12
12
|
|
|
13
|
-
](docs/screenshot-20231120-5.webp)<br>
|
|
14
14
|
|
|
15
15
|
## Motivation
|
|
16
16
|
|
|
@@ -18,7 +18,7 @@ Sveltia CMS was born in November 2022, when the progress of Netlify CMS was stal
|
|
|
18
18
|
|
|
19
19
|
To achieve radical improvements in UX, performance and i18n, it was decided to build an alternative from the ground up, while ensuring an easy migration path from the other. After proving the concept with a rapid [Svelte](https://svelte.dev/) prototype, development was accelerated to address their primary use cases. The new offering has since been released as open source software to encourage wider adoption.
|
|
20
20
|
|
|
21
|
-
Our goal is to make it a viable successor to Netlify CMS, expand the Git-based headless CMS market, empower small businesses and individuals who need a simple yet powerful CMS solution, and showcase the
|
|
21
|
+
Our goal is to make it a viable successor to Netlify CMS, expand the Git-based headless CMS market, empower small businesses and individuals who need a simple yet powerful CMS solution, and showcase the huge potential of the Svelte framework.
|
|
22
22
|
|
|
23
23
|
## Features
|
|
24
24
|
|
|
@@ -27,33 +27,32 @@ Here are some highlights mainly compared to Netlify/Decap CMS:
|
|
|
27
27
|
### Compatible with Netlify/Decap CMS
|
|
28
28
|
|
|
29
29
|
- Ready to replace Netlify/Decap CMS _in some casual use case scenarios_ by updating a single line of code.
|
|
30
|
-
-
|
|
31
|
-
- Various features are still missing though —
|
|
30
|
+
- Your existing [configuration file](https://decapcms.org/docs/configuration-options/) can be reused as is.
|
|
31
|
+
- Various features are still missing though — look at the [compatibility chart](#compatibility) below to see if you can migrate.
|
|
32
32
|
|
|
33
33
|
### Better UX
|
|
34
34
|
|
|
35
|
-
- Created and maintained by an [experienced UX engineer](https://github.com/kyoshino) who loves code and design. You can expect constant UX improvements.
|
|
36
|
-
- Offers a modern, intuitive
|
|
37
|
-
-
|
|
35
|
+
- Created and maintained by an [experienced UX engineer](https://github.com/kyoshino) who loves code and design. You can expect constant UX improvements across the platform.
|
|
36
|
+
- Offers a modern, intuitive user interface, including an immersive dark mode[^2], inspired in part by the Netlify CMS v3 prototype[^1].
|
|
37
|
+
- Comes with touch device support. While the UI is not yet optimized for small screens, large tablets like iPad Pro or Pixel Tablet should work well.
|
|
38
38
|
- The screenshots above are worth a thousand words!
|
|
39
39
|
|
|
40
40
|
### Better performance
|
|
41
41
|
|
|
42
42
|
- Built completely from scratch with Svelte instead of forking React-based Netlify/Decap CMS. The app starts fast and stays fast. The compiled code is vanilla JavaScript — you can use it with almost any framework.
|
|
43
|
+
- Small footprint: less than 300 KB when minified and gzipped, compared to 1.5 MB of Netlify/Decap CMS. And [no virtual DOM overhead](https://svelte.dev/blog/virtual-dom-is-pure-overhead).
|
|
43
44
|
- Uses the GraphQL API for GitHub to quickly fetch content at once, so that entries and assets can be listed and searched instantly. This avoids the slowness and potential API rate limit violations caused by hundreds of requests with relation widgets[^14].
|
|
44
45
|
- Saving entries and assets is also much faster thanks to the [GraphQL mutation](https://github.blog/changelog/2021-09-13-a-simpler-api-for-authoring-commits/).
|
|
45
46
|
- Caches Git files locally to further speed up startup and reduce bandwidth.
|
|
46
|
-
- Small footprint: less than 300 KB when minified and gzipped, compared to 1.5 MB of Netlify/Decap CMS. And [no virtual DOM overhead](https://svelte.dev/blog/virtual-dom-is-pure-overhead).
|
|
47
47
|
|
|
48
48
|
### Better productivity
|
|
49
49
|
|
|
50
50
|
- You can [work on a local Git repository](#work-with-a-local-git-repository) without having to run a proxy server on your machine.
|
|
51
51
|
- You can delete multiple entries and assets at once.
|
|
52
|
-
-
|
|
52
|
+
- Some keyboard shortcuts are available for faster editing. More to come!
|
|
53
53
|
- Create a new entry: `Ctrl+E` (Windows/Linux) / `Command+E` (macOS)
|
|
54
54
|
- Save an entry: `Ctrl+S` (Windows/Linux) / `Command+S` (macOS)
|
|
55
55
|
- Search for entries and assets: `Ctrl+F` (Windows/Linux) / `Command+F` (macOS)
|
|
56
|
-
- Offers a UI optimized for tablet devices. Note that the UI is not yet optimized for smaller screens.
|
|
57
56
|
- Solves various outstanding Netlify/Decap CMS bugs[^11].
|
|
58
57
|
|
|
59
58
|
### Better accessibility
|
|
@@ -82,12 +81,12 @@ Here are some highlights mainly compared to Netlify/Decap CMS:
|
|
|
82
81
|
|
|
83
82
|
- Required fields, not optional fields, are clearly marked for efficient data entry.
|
|
84
83
|
- Integration with Pexels, Pixabay and Unsplash makes it easy to insert free stock photos into image fields[^8].
|
|
85
|
-
- Optional object fields (`widget:object` with `required:false`) can be manually added or removed. If removed, the required subfields will no longer trigger validation errors[^16].
|
|
84
|
+
- Optional object fields (`widget: object` with `required: false`) can be manually added or removed. If removed, the required subfields will no longer trigger validation errors[^16].
|
|
86
85
|
- You can revert changes to all fields or a specific field.
|
|
87
86
|
|
|
88
|
-
###
|
|
87
|
+
### Asset Library enhancements
|
|
89
88
|
|
|
90
|
-
-
|
|
89
|
+
- A completely new Asset Library, built separately from the image selection dialog, makes it easy to manage all of your files, including images and documents.
|
|
91
90
|
- You can sort or filter assets by name or file type and view asset details, including size, dimensions, and a list of entries that use the selected asset.
|
|
92
91
|
- You can upload multiple assets at once, including files in nested folders, by browsing or dragging & dropping them into the media library[^5].
|
|
93
92
|
- You can navigate between the global media folder and a per-collection media folder[^6].
|
|
@@ -100,9 +99,9 @@ While it’s not our goal to recreate all the features found in Netlify/Decap CM
|
|
|
100
99
|
| --- | --- |
|
|
101
100
|
| Installation | Installing with npm is not supported yet. |
|
|
102
101
|
| UI locales | Only English and Japanese are available at this time. No registration is needed. While the UI locale is automatically selected depending on the browser’s language settings, it can be changed in Settings. (Click on the Account button in the top right corner of the CMS.) |
|
|
103
|
-
| Account | Only the [GitHub backend](https://decapcms.org/docs/github-backend/) is available at this time. You can keep using Netlify or a [3rd party OAuth client](https://decapcms.org/docs/external-oauth-clients/) (or [our own](https://github.com/sveltia/sveltia-cms-auth)) to sign in with GitHub, just like Netlify/Decap CMS. The GitLab backend is coming soon. We plan to add the Test backend as well for our demo site, but Azure and
|
|
102
|
+
| Account | Only the [GitHub backend](https://decapcms.org/docs/github-backend/) is available at this time. You can keep using Netlify or a [3rd party OAuth client](https://decapcms.org/docs/external-oauth-clients/) (or [our own](https://github.com/sveltia/sveltia-cms-auth)) to sign in with GitHub, just like Netlify/Decap CMS. The GitLab backend is coming soon. We plan to add the Test backend as well for our demo site, but Azure, Bitbucket and Git Gateway will probably not be supported, mainly due to the lack of a method to fetch content in bulk. We have not looked into the relatively new Gitea backend yet. Later we may implement a performant Git Gateway alternative using GraphQL. |
|
|
104
103
|
| Configuration | Supported. |
|
|
105
|
-
| Media | External media storage services are not supported yet. |
|
|
104
|
+
| Media | External media storage services are not supported yet. Deprecated Netlify Large Media won’t be added. |
|
|
106
105
|
| Editorial Workflow | Not supported yet. |
|
|
107
106
|
| Collections | Supported. |
|
|
108
107
|
| Widgets | [See below](#widget-limitations) for the current limitations. |
|
|
@@ -114,19 +113,19 @@ While it’s not our goal to recreate all the features found in Netlify/Decap CM
|
|
|
114
113
|
| Widget | Status in Sveltia CMS |
|
|
115
114
|
| --- | --- |
|
|
116
115
|
| Code | Not supported yet. |
|
|
117
|
-
| Color |
|
|
118
|
-
| Date/DateTime |
|
|
116
|
+
| Color | The `enableAlpha` option is not supported yet. |
|
|
117
|
+
| Date/DateTime | The `date_format` and `time_format` options with Moment.js tokens are not supported yet. We may deprecate the Moment.js format support anyway. |
|
|
119
118
|
| File/Image | Field-specific media folders and media library options are not supported yet other than `media_library.config.max_file_size` for the default media library. |
|
|
120
119
|
| Map | Not supported yet. |
|
|
121
120
|
| Markdown | It’s a plain text editor at this time. A rich text editor is coming soon. |
|
|
122
|
-
| Relation | The `search_fields`
|
|
121
|
+
| Relation | The `search_fields` option is not supported yet. |
|
|
123
122
|
|
|
124
123
|
### Beta features in Netlify/Decap CMS
|
|
125
124
|
|
|
126
125
|
| Feature | Status in Sveltia CMS |
|
|
127
126
|
| --- | --- |
|
|
128
127
|
| Working with a Local Git Repository | Supported. [See below](#work-with-a-local-git-repository) for details. |
|
|
129
|
-
| GitLab and BitBucket Editorial Workflow Support |
|
|
128
|
+
| GitLab and BitBucket Editorial Workflow Support | Editorial workflow is not supported yet. |
|
|
130
129
|
| i18n Support | Supported. In fact, i18n is at the core of Sveltia CMS! |
|
|
131
130
|
| GitHub GraphQL API | Supported. Sveltia CMS uses GraphQL by default for a better performance. It cannot be disabled. |
|
|
132
131
|
| GitLab GraphQL API | The GitLab backend is not supported yet. |
|
|
@@ -156,20 +155,20 @@ While it’s not our goal to recreate all the features found in Netlify/Decap CM
|
|
|
156
155
|
|
|
157
156
|
## Roadmap
|
|
158
157
|
|
|
158
|
+
- [Svelte 5](https://svelte.dev/blog/runes) migration
|
|
159
159
|
- Further Netlify/Decap CMS compatibility, including Editorial Workflow
|
|
160
|
-
- Further performance optimization, including data caching and [Svelte 5](https://svelte.dev/blog/runes) migration
|
|
161
|
-
- Further UX enhancements
|
|
162
160
|
- Config editor[^10]
|
|
161
|
+
- Mobile support[^18]
|
|
163
162
|
- Documentation
|
|
163
|
+
- Marketing site
|
|
164
164
|
- Demo site
|
|
165
165
|
- Starter templates
|
|
166
|
-
- Mobile support
|
|
167
166
|
|
|
168
167
|
## Getting started
|
|
169
168
|
|
|
170
169
|
### New users
|
|
171
170
|
|
|
172
|
-
Currently, Sveltia CMS is
|
|
171
|
+
Currently, Sveltia CMS is only intended for existing Netlify/Decap CMS users. If you don’t have it yet, follow [their documentation](https://decapcms.org/docs/add-to-your-site/) to add it to your site and create a configuration file first. Then migrate to Sveltia CMS as described below.
|
|
173
172
|
|
|
174
173
|
As the product evolves, we’ll implement a built-in configuration editor and provide comprehensive documentation to make it easier for everyone to get started with Sveltia CMS.
|
|
175
174
|
|
|
@@ -180,7 +179,7 @@ Here are some starter kits for popular frameworks created by community members.
|
|
|
180
179
|
|
|
181
180
|
### Migration
|
|
182
181
|
|
|
183
|
-
If you’re already using Netlify/Decap CMS with the GitHub backend and don’t have any custom widget, custom preview or plugin, migrating to Sveltia CMS is super easy. Edit `/admin/index.html` to replace the CMS `script` tag, and push the change to your repository:
|
|
182
|
+
Have a look at the [compatibility chart](#compatibility) above first. If you’re already using Netlify/Decap CMS with the GitHub backend and don’t have any custom widget, custom preview or plugin, migrating to Sveltia CMS is super easy. Edit `/admin/index.html` to replace the CMS `script` tag, and push the change to your repository:
|
|
184
183
|
|
|
185
184
|
```diff
|
|
186
185
|
-<script src="https://unpkg.com/netlify-cms@^2.0.0/dist/netlify-cms.js"></script>
|
|
@@ -206,11 +205,12 @@ You can use Sveltia CMS with a local Git repository, like the [beta feature](htt
|
|
|
206
205
|
1. Click “Work with Local Repository” and select the project’s root directory once prompted.
|
|
207
206
|
1. Make some changes to your content on Sveltia CMS.
|
|
208
207
|
1. See if the produced changes look good using `git diff` or a GUI like [GitHub Desktop](https://desktop.github.com/).
|
|
208
|
+
1. Open the dev site at `http://localhost:[port]/` to check the rendered results.
|
|
209
209
|
1. Commit and push the changes if satisfied, or discard them if you’re just testing.
|
|
210
210
|
|
|
211
211
|
### Use a custom icon for a collection
|
|
212
212
|
|
|
213
|
-
|
|
213
|
+
You can have an icon for each collection for easy identification in the collection list.
|
|
214
214
|
|
|
215
215
|
1. Visit the [Material Symbols](https://fonts.google.com/icons?icon.set=Material+Symbols&icon.platform=android) page on Google Fonts.
|
|
216
216
|
1. Search and select an icon, and copy the icon name displayed on the right panel.
|
|
@@ -380,3 +380,4 @@ This software is provided “as is” without any express or implied warranty. T
|
|
|
380
380
|
[^15]: [Netlify/Decap CMS #6932](https://github.com/decaporg/decap-cms/issues/6932)
|
|
381
381
|
[^16]: [Netlify/Decap CMS #2103](https://github.com/decaporg/decap-cms/issues/2103)
|
|
382
382
|
[^17]: [Netlify/Decap CMS #1333](https://github.com/decaporg/decap-cms/issues/1333)
|
|
383
|
+
[^18]: [Netlify/Decap CMS #441](https://github.com/decaporg/decap-cms/issues/441)
|