es6ify js snippets

This commit is contained in:
Thomas Ruoff
2017-03-07 23:03:22 +01:00
committed by Thomas Ruoff
parent d20a3b8daf
commit accb586c6e
2 changed files with 10 additions and 46 deletions

View File

@@ -5,37 +5,37 @@ priority -50
# #
snippet des "Describe (js)" b snippet des "Describe (js)" b
describe('${1:description}', function() { describe('${1:description}', () => {
$0 $0
}); });
endsnippet endsnippet
snippet it "it (js)" b snippet it "it (js)" b
it('${1:description}', function() { it('${1:description}', () => {
$0 $0
}); });
endsnippet endsnippet
snippet bef "before each (js)" b snippet bef "before each (js)" b
beforeEach(function() { beforeEach(() => {
$0 $0
}); });
endsnippet endsnippet
snippet aft "after each (js)" b snippet aft "after each (js)" b
afterEach(function() { afterEach(() => {
$0 $0
}); });
endsnippet endsnippet
snippet befa "before all (js)" b snippet befa "before all (js)" b
beforeAll(function() { beforeAll(() => {
$0 $0
}); });
endsnippet endsnippet
snippet afta "after all (js)" b snippet afta "after all (js)" b
afterAll(function() { afterAll(() => {
$0 $0
}); });
endsnippet endsnippet
@@ -63,7 +63,7 @@ jasmine.stringMatching("${1:matcher}")
endsnippet endsnippet
snippet ru "runs (js)" b snippet ru "runs (js)" b
runs(function() { runs(() => {
$0 $0
}); });
endsnippet endsnippet

View File

@@ -5,47 +5,11 @@ priority -30
snippet def "define an AMD module" snippet def "define an AMD module"
define([ define([
'${1:backbone}' '${1:backbone}'
], function( ], (
${2:Name}) ${2:Backbone})
) { ) => {
$0 $0
} }
endsnippet endsnippet
# Jasmine
snippet des "Describe (js)" b
describe('${1:description}', function() {
$0
});
endsnippet
snippet it "it (js)" b
it('${1:description}', function() {
$0
});
endsnippet
snippet bef "before each (js)" b
beforeEach(function() {
$0
});
endsnippet
snippet aft "after each (js)" b
afterEach(function() {
$0
});
endsnippet
snippet befa "before all (js)" b
beforeAll(function() {
$0
});
endsnippet
snippet afta "after all (js)" b
afterAll(function() {
$0
});
endsnippet
# vim:ft=snippets: # vim:ft=snippets: