Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Grunt: The JavaScript Task Runner
Search
Sebastiaan Deckers
February 25, 2013
Programming
8
400
Grunt: The JavaScript Task Runner
Slides for my talk at Front-end Developers User Group (Singapore)
Sebastiaan Deckers
February 25, 2013
Tweet
Share
More Decks by Sebastiaan Deckers
See All by Sebastiaan Deckers
Commons Host: Building a CDN for the rest of the world
sebdeckers
1
130
SVG Reality
sebdeckers
5
140
About Sebastiaan
sebdeckers
0
150
Frontend 100
sebdeckers
1
490
Frontend 101
sebdeckers
4
540
Frontend 102
sebdeckers
3
490
Frontend 103
sebdeckers
2
480
Frontend Testing
sebdeckers
3
340
Other Decks in Programming
See All in Programming
GoとPHPのインターフェイスの違い
shimabox
2
170
iOSエンジニアから始める visionOS アプリ開発
nao_randd
3
130
Amazon Bedrock Multi Agentsを試してきた
tm2
1
280
AWS Lambda functions with C# 用の Dev Container Template を作ってみた件
mappie_kochi
0
240
ARA Ansible for the teams
kksat
0
150
Unity Android XR入門
sakutama_11
0
150
Flutter × Firebase Genkit で加速する生成 AI アプリ開発
coborinai
0
150
AWS Organizations で実現する、 マルチ AWS アカウントのルートユーザー管理からの脱却
atpons
0
130
Rails アプリ地図考 Flush Cut
makicamel
1
110
Grafana Loki によるサーバログのコスト削減
mot_techtalk
1
120
ファインディの テックブログ爆誕までの軌跡
starfish719
2
1.1k
法律の脱レガシーに学ぶフロントエンド刷新
oguemon
5
730
Featured
See All Featured
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
6
550
How to Ace a Technical Interview
jacobian
276
23k
Typedesign – Prime Four
hannesfritz
40
2.5k
Building Your Own Lightsaber
phodgson
104
6.2k
Six Lessons from altMBA
skipperchong
27
3.6k
The Power of CSS Pseudo Elements
geoffreycrofte
75
5.5k
Designing for humans not robots
tammielis
250
25k
Optimizing for Happiness
mojombo
376
70k
Into the Great Unknown - MozCon
thekraken
35
1.6k
Done Done
chrislema
182
16k
Fireside Chat
paigeccino
34
3.2k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Transcript
The JavaScript Task Runner
What is Grunt? Grunt is like Ant, Make, Rake, SCons,
etc. but, Javascript. NPM.
build script
Automate your build So you can: ... do continuous integration,
... release to production without fear, ... work on more interesting things.
Is Grunt for me? frontend backend mixed Backbone, Ember, Angular
REST/WebSocket API Express.js
Grunt Plugins grunt-contrib: 26 and growing Community: 450+
None
Using Grunt 1. Create package.json 2. Gruntfile.js 3. Run npm
install 4. grunt [task[:target]]
package.json { "name": "hello-world", "version": "0.1.0", "dependencies": { "grunt": "~0.4.0",
"grunt-contrib-jshint": "~0.1.1", "grunt-contrib-uglify": "~0.1.1" } }
Gruntfile.js module.exports = function (grunt) { grunt.initConfig({ uglify: { build:
{ src: 'app.js', dest: 'build/app.min.js' } }, jshint: { all: ['**/*.js'] } }); grunt.loadNpmTasks('grunt-contrib-uglify'); grunt.loadNpmTasks('grunt-contrib-jshint'); grunt.registerTask('default', ['jshint', 'uglify']); };
Have it your way Declarative Imperative
Demo
Poor Man's CI $ sudo -i # crontab -e */5
* * * * cd /var/www/myapp.com && git reset --hard && git pull origin master && npm install && npm test && grunt
I am Sebastiaan I email
[email protected]
I blog ninja.sg I
work cf.sg I code git.io/seb