[RFC] Move chain/can under commands
See original GitHub issueI keep stumbling over the use of commands with and without chain
/can
:
// unchained
editor.commands.setBold()
// chained
editor.chain().setBold().run()
// unchained can
editor.can().setBold()
// chained can
editor.can().chain().setBold().run()
I’m thinking about whether chain
/can
should only available under commands:
// unchained
editor.commands.setBold()
// chained
editor.commands.chain().setBold().run()
// unchained can
editor.commands.can().setBold()
// chained can
editor.commands.can().chain().setBold().run()
What do you think? Or do you have other ideas?
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
RFC 6851: Internet Message Access Protocol (IMAP) - MOVE ...
This is accomplished by defining a new MOVE command and extending the UID command to allow UID MOVE. A move function is not...
Read more >RFC 7151 - File Transfer Protocol HOST Command for Virtual ...
1. REIN Command Semantics As specified in [RFC959], the REIN command returns the state of the connection to what it was immediately after...
Read more >The keytool Command - Oracle Help Center
The keytool command stores the keys and certificates in a keystore. ... Braces are also used around the -v , -rfc , and...
Read more >BGP - RouterOS - MikroTik Documentation - Support
More information on BGP roles can be found in the corresponding RFC draft ... Also, in this menu is located a session-specific set...
Read more >iptables - ArchWiki - Arch Linux
iptables is a command line utility for configuring Linux kernel firewall implemented within the Netfilter project. The term iptables is also ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I not sure I like that, the chains are rather lovely.
I think I would leave it as is for now and see how people get on, if you become inundated with new users getting it wrong then you can revisit it and always depreciate the current way of doing it.
They way I think of it is:
editor.commands
: the raw commandseditor.can()
&editor.chain()
magic ways of using the commandsI’m closing this here as it feels like a non-issue for people. @philippkuehn feel free to reopen it, if you think we should change that.