TryGhost / Ghost

Independent technology for modern publishing, memberships, subscriptions and newsletters.
https://ghost.org
MIT License
47.47k stars 10.35k forks source link

in-content shortcodes #6785

Closed stevenvachon closed 8 years ago

stevenvachon commented 8 years ago

... like in WordPress:

Welcome to my [shortcode]. It will [shortcode attr="value"]do some stuff[/shortcode].

Does Ghost currently support this feature? If not, we definitely need it, especially with interesting things like shortcake

ErisDS commented 8 years ago

Hi there @stevenvachon, Ghost does not support shortcodes and we will not be adding support, very sorry.

stevenvachon commented 8 years ago

What's the reason?

ErisDS commented 8 years ago

Google "WordPress shortcode problem" - it is a nightmare feature that causes constant compatibility issues. There's no built-in consideration for importing/exporting content, or what happens if the plugin that adds the shortcode stops being maintained.

The same thing can easily be achieved by installing something like textexpander, but without impacting on your data.

stevenvachon commented 8 years ago

What if Ghost shortcodes were mustache/handlebars syntax? They wouldn't look like [sic], making it easier to search for them during a migration.

ErisDS commented 8 years ago

Changing the syntax really doesn't solve any of the underlying problems I described. As I said, textexpander solves the same problem without affecting your data. Editor extensions are something on our radar, but they will be taking a different form. Shortcodes are categorically not something we're going to add, sorry again.

stevenvachon commented 8 years ago

TextExpander is just static snippets and not dynamic on the server.

Perhaps shortcodes/helpers could be a plugin created. Is the plugin API going to be v0.8?

ErisDS commented 8 years ago

No, there's not going to be a plugin API for the editor any time soon - again, all the same problems apply.

If this is the killer feature for you, then Ghost is not the tool for the job.