atom / language-todo

TODO highlighting package for Atom
Other
81 stars 66 forks source link

Q/A: how to disable idea snnipets. #58

Closed dhun closed 5 years ago

dhun commented 7 years ago

A generic entity class has an ID field defined. When the idea snippet is defined, the following will be listed whe enter entity.i.

Is there any way to disable the idea snippet? Or whether you can set whether to use the idea snippet or not?

I am using language-todo while commenting out idea part of language-todo/snippets/todo.cson.

I think that it is not much to use the idea snippet compared to the ID field. I think that there are many people in trouble for the same reason. I am really happy to provide it as a package feature. plz

piuccio commented 7 years ago

I hate the snippet question, would be nice to have a way to configure which snippets are active

Stanko commented 6 years ago

Same here. QUESTION is really annoying.

Plus in CSS files when I start typing word color (font-co, border-co...) autocomplete offers COMBAK as first option.

mrleblanc101 commented 6 years ago

Snippets suggestions should only be enabled in comments as TODO/FIX statement are only used in comments. Furthermore the syntax highlighting is only for comments so it would only make sense and would fix this problem. Writing CSS in comments is very rare so still having these suggestions wouldn't really be a problem.

nickrw commented 6 years ago

This isn't an officially supported method, but it works as a hacky workaround until it is:

You can override snippets for a particular scope in ~/.atom/snippets.cson and not populate the body, effectively disabling it:

'.source.foo':
    'idea':
        'prefix': 'idea'
      'todo':
        'prefix': 'todo'
combizs commented 6 years ago

I would suggest changing the key-bindings to convert the codesnippet... only on tab. That way you won't have a long list of items in a file tucked away. It won't solve what you are specifically asking for, but is a solution to avoid autocompleting your code with an unwanted snippet.

Otherwise, similar to @nickrw's solution above, you can disable the snippet:

'.source.foo':
    'idea':
        'prefix': 'idea'
        'disabled' true
axe-z commented 5 years ago

There should be a compiled snippet file, where you see every snippet , your own, and the added ones, and be able to clean up stuff . AND a grammar default selection for extension ..

Ben3eeE commented 5 years ago

Atom 1.33 (currently in beta) has the ability to disable all snippets from any language package that includes snippets like language-todo from the packages settings. If you want to add some of them back there is a copy button so you can paste it to your personal snippets file.

image


Thanks for reaching out!

Because we treat our issues list as the Atom team's backlog, we close issues that are questions since they don't represent a task needing to be completed. For most questions about Atom there are a lot of options, check out:

On Discuss and in the Atom Slack team, there are a bunch of helpful community members that should be willing to point you in the right direction.

axe-z commented 5 years ago

wow I did add the line for the empty body, atom is not restarting.. no safe mode. I see atom in the upper corner with only quit in the menu

axe-z commented 5 years ago

capture d ecran le 2018-11-15 a 18 41 30 any idea ? is there a way out ... except vscode... installed it again. removed files from librairy... tried atom --safe ... nothing