From 1d9f152cece7b01a24e185ac394b8792ddb03dc9 Mon Sep 17 00:00:00 2001 From: Ankur Patel Date: Mon, 28 Jan 2019 16:24:43 -0500 Subject: [PATCH] Add snippets for ember-decorators package --- .../import-ember-decorators-component.cson | 26 +++ .../import-ember-decorators-controller.cson | 6 + snippets/import-ember-decorators-data.cson | 16 ++ ...port-ember-decorators-object-computed.cson | 161 ++++++++++++++++++ snippets/import-ember-decorators-object.cson | 36 ++++ snippets/import-ember-decorators-service.cson | 6 + 6 files changed, 251 insertions(+) create mode 100644 snippets/import-ember-decorators-component.cson create mode 100644 snippets/import-ember-decorators-controller.cson create mode 100644 snippets/import-ember-decorators-data.cson create mode 100644 snippets/import-ember-decorators-object-computed.cson create mode 100644 snippets/import-ember-decorators-object.cson create mode 100644 snippets/import-ember-decorators-service.cson diff --git a/snippets/import-ember-decorators-component.cson b/snippets/import-ember-decorators-component.cson new file mode 100644 index 0000000..ba997c5 --- /dev/null +++ b/snippets/import-ember-decorators-component.cson @@ -0,0 +1,26 @@ +'.source.js, .source.ts': + + 'Ember.component.attribute': + 'prefix': 'imdecattribute', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { attribute } from '@ember-decorators/component;'" + + 'Ember.component.className': + 'prefix': 'imdecclassName', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { className } from '@ember-decorators/component;'" + + 'Ember.component.classNames': + 'prefix': 'imdecclassNames', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { classNames } from '@ember-decorators/component;'" + + 'Ember.component.layout': + 'prefix': 'imdeclayout', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { layout } from '@ember-decorators/component;'" + + 'Ember.component.tagName': + 'prefix': 'imdectagName', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { tagName } from '@ember-decorators/component;'" diff --git a/snippets/import-ember-decorators-controller.cson b/snippets/import-ember-decorators-controller.cson new file mode 100644 index 0000000..4a956d2 --- /dev/null +++ b/snippets/import-ember-decorators-controller.cson @@ -0,0 +1,6 @@ +'.source.js, .source.ts': + + 'Ember.inject.controller': + 'prefix': 'imdecinjectController' + 'leftLabelHTML': 'Ember Decorators module' + 'body': "import { inject as controller } from '@ember-decorators/controller';" diff --git a/snippets/import-ember-decorators-data.cson b/snippets/import-ember-decorators-data.cson new file mode 100644 index 0000000..70a50ea --- /dev/null +++ b/snippets/import-ember-decorators-data.cson @@ -0,0 +1,16 @@ +'.source.js, .source.ts': + + 'Ember.data.attr': + 'prefix': 'imdecattr', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { attribute } from '@ember-decorators/data;'" + + 'Ember.data.belongsTo': + 'prefix': 'imdecbelongsTo', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { className } from '@ember-decorators/data;'" + + 'Ember.data.hasMany': + 'prefix': 'imdechasMany', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { classNames } from '@ember-decorators/data;'" diff --git a/snippets/import-ember-decorators-object-computed.cson b/snippets/import-ember-decorators-object-computed.cson new file mode 100644 index 0000000..c4ea1ed --- /dev/null +++ b/snippets/import-ember-decorators-object-computed.cson @@ -0,0 +1,161 @@ +'.source.js, .source.ts': + + 'Ember.computed.alias': + 'prefix': 'imdecalias', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { alias } from '@ember-decorators/object/computed;'" + + 'Ember.computed.and': + 'prefix': 'imdecand', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { and } from '@ember-decorators/object/computed;'" + + 'Ember.computed.bool': + 'prefix': 'imdecbool', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { bool } from '@ember-decorators/object/computed;'" + + 'Ember.computed.collect': + 'prefix': 'imdeccollect', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { collect } from '@ember-decorators/object/computed;'" + + 'Ember.computed.deprecatingAlias': + 'prefix': 'imdecdeprecatin', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { deprecatingAlias } from '@ember-decorators/object/computed;'" + + 'Ember.computed.empty': + 'prefix': 'imdecempty', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { empty } from '@ember-decorators/object/computed;'" + + 'Ember.computed.equal': + 'prefix': 'imdecequal', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { equal } from '@ember-decorators/object/computed;'" + + 'Ember.computed.filter': + 'prefix': 'imdecfilter', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { filter } from '@ember-decorators/object/computed;'" + + 'Ember.computed.filterBy': + 'prefix': 'imdecfilterBy', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { filterBy } from '@ember-decorators/object/computed;'" + + 'Ember.computed.gt': + 'prefix': 'imdecgt', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { gt } from '@ember-decorators/object/computed;'" + + 'Ember.computed.gte': + 'prefix': 'imdecgte', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { gte } from '@ember-decorators/object/computed;'" + + 'Ember.computed.intersect': + 'prefix': 'imdecintersect', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { intersect } from '@ember-decorators/object/computed;'" + + 'Ember.computed.lt': + 'prefix': 'imdeclt', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { lt } from '@ember-decorators/object/computed;'" + + 'Ember.computed.lte': + 'prefix': 'imdeclte', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { lte } from '@ember-decorators/object/computed;'" + + 'Ember.computed.map': + 'prefix': 'imdecmap', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { map } from '@ember-decorators/object/computed;'" + + 'Ember.computed.mapBy': + 'prefix': 'imdecmapBy', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { mapBy } from '@ember-decorators/object/computed;'" + + 'Ember.computed.match': + 'prefix': 'imdecmatch', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { match } from '@ember-decorators/object/computed;'" + + 'Ember.computed.max': + 'prefix': 'imdecmax', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { max } from '@ember-decorators/object/computed;'" + + 'Ember.computed.min': + 'prefix': 'imdecmin', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { min } from '@ember-decorators/object/computed;'" + + 'Ember.computed.none': + 'prefix': 'imdecnone', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { none } from '@ember-decorators/object/computed;'" + + 'Ember.computed.not': + 'prefix': 'imdecnot', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { not } from '@ember-decorators/object/computed;'" + + 'Ember.computed.notEmpty': + 'prefix': 'imdecnotEmpty', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { notEmpty } from '@ember-decorators/object/computed;'" + + 'Ember.computed.oneWay': + 'prefix': 'imdeconeWay', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { oneWay } from '@ember-decorators/object/computed;'" + + 'Ember.computed.or': + 'prefix': 'imdecor', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { or } from '@ember-decorators/object/computed;'" + + 'Ember.computed.readOnly': + 'prefix': 'imdecreadOnly', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { readOnly } from '@ember-decorators/object/computed;'" + + 'Ember.computed.reads': + 'prefix': 'imdecreads', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { reads } from '@ember-decorators/object/computed;'" + + 'Ember.computed.setDiff': + 'prefix': 'imdecsetDiff', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { setDiff } from '@ember-decorators/object/computed;'" + + 'Ember.computed.sort': + 'prefix': 'imdecsort', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { sort } from '@ember-decorators/object/computed;'" + + 'Ember.computed.sum': + 'prefix': 'imdecsum', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { sum } from '@ember-decorators/object/computed;'" + + 'Ember.computed.union': + 'prefix': 'imdecunion', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { union } from '@ember-decorators/object/computed;'" + + 'Ember.computed.uniq': + 'prefix': 'imdecuniq', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { uniq } from '@ember-decorators/object/computed;'" + + 'Ember.computed.uniqBy': + 'prefix': 'imdecuniqBy', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { uniqBy } from '@ember-decorators/object/computed;'" diff --git a/snippets/import-ember-decorators-object.cson b/snippets/import-ember-decorators-object.cson new file mode 100644 index 0000000..2bfd04d --- /dev/null +++ b/snippets/import-ember-decorators-object.cson @@ -0,0 +1,36 @@ +'.source.js, .source.ts': + + 'Ember.object.action': + 'prefix': 'imdecaction', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { attribute } from '@ember-decorators/component;'" + + 'Ember.object.computed': + 'prefix': 'imdeccomputed', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { className } from '@ember-decorators/component;'" + + 'Ember.object.observes': + 'prefix': 'imdecobserves', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { classNames } from '@ember-decorators/component;'" + + 'Ember.object.off': + 'prefix': 'imdecoff', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { attribute } from '@ember-decorators/component;'" + + 'Ember.object.on': + 'prefix': 'imdecon', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { className } from '@ember-decorators/component;'" + + 'Ember.object.unobserves': + 'prefix': 'imdecunobserves', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { classNames } from '@ember-decorators/component;'" + + 'Ember.object.wrapComputed': + 'prefix': 'imdecwrapComputed', + 'leftLabelHTML': 'Ember Decorators module', + 'body': "import { tagName } from '@ember-decorators/component;'" diff --git a/snippets/import-ember-decorators-service.cson b/snippets/import-ember-decorators-service.cson new file mode 100644 index 0000000..35e31e2 --- /dev/null +++ b/snippets/import-ember-decorators-service.cson @@ -0,0 +1,6 @@ +'.source.js, .source.ts': + + 'Ember.inject.service': + 'prefix': 'imdecinjectService' + 'leftLabelHTML': 'Ember Decorators module' + 'body': "import { inject as service } from '@ember-decorators/service';"