atom / snippets

Atom snippets package
MIT License
205 stars 100 forks source link

Provide a options to set the min word length of snippets. #227

Closed NanerLee closed 7 years ago

NanerLee commented 7 years ago

like the autocomplete-plus package.

lee-dohm commented 7 years ago

Can you give some more details on what you're asking for? As this issue stands right now, there isn't enough information to determine what to do.

NanerLee commented 7 years ago

Oh, sorry, I spelt the word wrong. It should be 'min', not 'mini'. If you are still puzzled, please see below.

For example:

when i press 'i' key, it will show me: 2016-12-24 16-30-09

but these snippets always bore me. so i want set the min length of word. For example, i set the min length to 2. Then when I press 'i' and 'f', it will show me some snippets.

hpfdf commented 7 years ago

+1 one letter completion makes the whole snippets feature unscalable. Adding an option like 'minLength' would be great.

` 'cerr': 'prefix': 'cerr' 'minLength': 2 'body': 'cerr << $1 << endl;'

'cin': 'prefix': 'cin' 'minLength': 2 'body': 'cin >> $1;'

'cout': 'prefix': 'cout' 'minLength': 2 'body': 'cout << $1 << endl;'`

lee-dohm commented 7 years ago

Thank you for your submission!

We noticed that this is a duplicate of https://github.com/atom/autocomplete-snippets/issues/75. You may want to subscribe there for updates.

Because we treat our issues list as the Atom team's backlog, we close duplicates to focus our work and not have to touch the same chunk of code for the same reason multiple times. This is also why we may mark something as duplicate that isn't an exact duplicate but is closely related.

For information on how to use GitHub's search feature to find out if something is a duplicate before filing, see the How Can I Contribute? section of the Atom CONTRIBUTING guide.