In emacs is there a mode where if I type ( it autocloses it like so (), but if I put it infront of a word like so (word it doesnt do ()word, but just intelligently stays like (word? I've tried smartparens and autopair to no avail, but maybe i haven't configured them correctly?
Use the built-in (as of version 24.something) electric-pair-mode
with conservative pairing:
(setq-default electric-pair-inhibit-predicate 'electric-pair-conservative-inhibit)
(electric-pair-mode 1)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With