Live data from Hacker News

Slate – A completely customizable framework for building rich text editors

github.com

1–10 of 52 posts

Re: Slate – A completely customizable framework for building rich text editors

#3

Been looking for something like this but minus React for _ages_. I'd like our users to build their own RTE according to their needs, having a common data model on every one of them. Is there such a thing out there?

Have a look at ProseMirror, let us know if this seems like what you want!

https://prosemirror.net/

Re: Slate – A completely customizable framework for building rich text editors

#5

Been looking for something like this but minus React for _ages_. I'd like our users to build their own RTE according to their needs, having a common data model on every one of them. Is there such a thing out there?

Based on ProseMirror, more popular than raw ProseMirror, inspired by Slate (years ago), but framework-agnostic and more advanced in some areas (like collaborative editing):

https://tiptap.dev

Re: Slate – A completely customizable framework for building rich text editors

#6
post #4

No image support? It’s the main thing that’s a pain in the ass to support.

There are editors that handle images very well by default, like Quill or Trix.

If you start diving deeper you’ll find out that image handling is just super complex and the behaviour is dependant on what you’re building. Then you’ll be happy to have full control about the behaviour with editors like Slate, ProseMirror or Tiptap.

Re: Slate – A completely customizable framework for building rich text editors

#7
post #4

No image support? It’s the main thing that’s a pain in the ass to support.

There are editors that handle images very well by default, like Quill or Trix. If you start diving deeper you’ll find out that image handling is just super complex and the behaviour is dependant on what you’re building. Then you’ll be happy to have full control about the behaviour with editors like Slate, ProseMirror or Tiptap.

The customisability is definitely a plus, you can make slate fit in perfectly with almost any UI. Whilst you don't get complex image handling by default, I think their image handling example [0] is a really nice minimal implementation which is quite intuitive.

[0] - https://www.slatejs.org/examples/images

Re: Slate – A completely customizable framework for building rich text editors

#9
post #4

No image support? It’s the main thing that’s a pain in the ass to support.

The basic package is bare though very much functional. The problem with whatabout's for such an editor is what do you put behind "image support"?

Some would need uploads, others just links, then copy and pasting, alt, captions, styling, etc...

Slate makes it easy to extend its core with custom blocks. Now, it's definitely some work but it's actually very intuitive to work with.

Re: Slate – A completely customizable framework for building rich text editors

#10
Word of warning, their readme says 'Some of its APIs are not "finalized" and will have breaking changes over time as we discover better solutions.'

I started using this library several years ago and have eventually had to rework it using prosemirror because I just couldn't keep up with the breaking changes.

Both libraries work in very similar ways, with slate using React for its rendering layer. However Prosemirror has been v1 for quite a while and in retrospect I'd have saved myself a lot of headaches if I'd taken the above warning more seriously.

Post reply on HN