brackets-snippets icon indicating copy to clipboard operation
brackets-snippets copied to clipboard

Parameters containing spaces

Open joepie91 opened this issue 10 years ago • 2 comments

Currently, when wanting to use a parameter that contains one or more spaces in a snippet, you need to enclose this value in ' or ". However, the apostrophes/quotation marks are not removed in this case.

For example, the following snippet (assuming the snippet name is hello):

Hi $${name}!

hello John Doe results in:

Hi John!Doe

hello "John Doe" results in:

Hi "John Doe"!

hello 'John Doe' results in:

Hi 'John Doe'!

The desired, but seemingly impossible result is:

Hi John Doe!

Is it possible to achieve this already, or is this simply a bug?

joepie91 avatar May 09 '14 22:05 joepie91

Same issue here, getting kinda hard using a multi-class-div-snippet there :D

mihawk90 avatar Jun 09 '14 23:06 mihawk90

Same problem here, for me this is a major roadblock to permanently utilizing this plugin.

At the very least escaping out whitespace should work.

ie: /*h1 This\ Stuff -> /* ----------- This Stuff ------------*/

But preferrably, quotes in the usual JS syntax style: /*h1 "This Stuff"

bitfed avatar Sep 07 '14 18:09 bitfed