2
I’m trying to create my own snippets on Atom, but none of them work at all.
tried:
'*':
'Controller text'
'prefix': 'lco'
'body': 'my name is $1'
but when typing lco
and press TAB, does nothing, also tried for php
'.source.php':
'Controller text'
'prefix': 'lco'
'body': 'my name is $1'
and for html
'.source.html':
'Controller text'
'prefix': 'lco'
'body': 'my name is $1'
or
'.text.html':
'Controller text'
'prefix': 'lco'
'body': 'my name is $1'
In none of the ways I create my personal snippets Atom creates the snippets. In the above cases are examples to simplify what I wish to do.
What is the right way to work with snippets in Atom? I’ve followed examples of the documentation and can’t get the expected results.
Att. Thiago Prado
Thank you, really a very silly mistake on my part! But I didn’t notice in any way, even looking at the examples, bad part of not having a Bugger.
– Thiago Prado
You can access Development Tools from the View > Developer menu. That’s how I found out what was wrong.
– andref
Taking advantage would know how to appear the options of a placehold area? I’m trying:
'.source.php':
 'laravel route':
 'prefix': 'route'
 'body': 'Route::${1|get,post,resource,any,matched,pattern,filter|}(\'${2:/}\', ${3:function(){\n
 \t${4:...};
 \n}});'
But not right, and has no information on how to do it correctly by coffeescript. And also does not generate error.– Thiago Prado