SlideShare a Scribd company logo
1 of 22
Download to read offline
BUILD TOOL
BROCCOLI
WAT?BROCCOLI
WAT?
Fast build pipeline from Ember
that you can use without Ember
BROCCOLI
WAT?
Composable plugin system
Highly performant with sub-second speeds
Easy to setup and use in a new project
BROCCOLI
HOW?
Given the above project structure…
.
+-- app
| +-- css
| +-- js
| +-- img
| +-- index.html
+-- node_modules/
+-- .gitignore
+-- Brocfile.js
+-- README.md
+-- package.json
BROCCOLI
.
+-- app
| +-- css
| +-- js
| +-- img
| +-- index.html
+-- node_modules/
+-- .gitignore
+-- Brocfile.js
+-- README.md
+-- package.json
HOW?
We want to bundle all this stuff and provide it to
the end user
BROCCOLI
HOW?
$> npm install -g broccoli-cli
$> npm install --save-dev broccoli
BROCCOLI
HOW?
$> npm i --save-dev broccoli-concat
$> npm i --save-dev broccoli-merge-trees
$> npm i --save-dev broccoli-static-compiler
$> npm i --save-dev broccoli-uglify-js
BROCCOLI
HOW?
$> vim Brocfile.js
BROCCOLI
.
+-- app
| +-- css
| +-- js
| +-- img
| +-- index.html
+-- node_modules/
+-- .gitignore
+-- Brocfile.js
+-- README.md
+-- package.json
HOW?
pick this directly
BROCCOLI
HOW?
const pickFiles = require(‘broccoli-static-compiler');
const mergeTrees = require('broccoli-merge-trees');
const app = 'app';
let appHTML = pickFiles(app, {
srcDir: '/',
files: ['index.html'],
destDir: '/'
});
module.exports = mergeTrees([appHTML]);
BROCCOLI
.
+-- app
| +-- css
| +-- js
| +-- img
| +-- index.html
+-- node_modules/
+-- .gitignore
+-- Brocfile.js
+-- README.md
+-- package.json
HOW?
pick this directly too
BROCCOLI
HOW?
const pickFiles = require(‘broccoli-static-compiler');
const mergeTrees = require('broccoli-merge-trees');
const app = 'app';
let appHTML = pickFiles(app, {
srcDir: '/',
files: ['index.html'],
destDir: '/'
});
let appImages = pickFiles(app, {
srcDir: '/img',
files: ['**/*'],
destDir: '/img'
});
module.exports = mergeTrees([appHTML, appImages]);
BROCCOLI
.
+-- app
| +-- css
| +-- js
| +-- img
| +-- index.html
+-- node_modules/
+-- .gitignore
+-- Brocfile.js
+-- README.md
+-- package.json
HOW?
put ‘em together and uglify
BROCCOLI
HOW?
const pickFiles = require(‘broccoli-static-compiler’);
const mergeTrees = require('broccoli-merge-trees');
const concatenate = require(‘broccoli-concat');
const uglifyJS = require('broccoli-uglify-js');
// …
let appJS = concatenate(app, {
inputFiles: ['js/**/*.js'],
outputFile: '/app.js'
});
appJS = uglifyJS(appJS, {
compress: true
});
module.exports = mergeTrees([appHTML, appImages, appJS]);
BROCCOLI
.
+-- app
| +-- css
| +-- js
| +-- img
| +-- index.html
+-- node_modules/
+-- .gitignore
+-- Brocfile.js
+-- README.md
+-- package.json
HOW?
put ‘em together
BROCCOLI
HOW?
const pickFiles = require(‘broccoli-static-compiler’);
const mergeTrees = require('broccoli-merge-trees');
const concatenate = require(‘broccoli-concat');
const uglifyJS = require('broccoli-uglify-js');
// …
let appCSS = concatenate(app, {
inputFiles: ['css/**/*.css'],
outputFile: '/app.css'
});
module.exports = mergeTrees([appHTML, appImages, appJS, appCSS]);
BROCCOLI
HOW?$> broccoli serve
Serving on http://localhost:4200
Slowest Trees | Total
----------------------------------------------+---------------------
SourceMapConcat | 16ms
UglifyJSFilter | 11ms
BroccoliMergeTrees | 11ms
StaticCompiler | 6ms
SimpleConcat | 3ms
StaticCompiler | 3ms
Slowest Trees (cumulative) | Total (avg)
----------------------------------------------+---------------------
SourceMapConcat (1) | 16ms
UglifyJSFilter (1) | 11ms
BroccoliMergeTrees (1) | 11ms
StaticCompiler (2) | 9ms (4 ms)
SimpleConcat (1) | 3ms
Built - 55 ms @ Fri Sep 02 2016 16:01:26 GMT-0400 (EDT)
BROCCOLI
HOW?
$> broccoli build 'dist'
BROCCOLI
NOW WHUT?BROCCOLI
NOW WHUT?BROCCOLI
Transpile ES6 modules with Babel
https://github.com/givanse/broccoli-babel-examples
Add live-reloading
https://github.com/stfsy/broccoli-livereload
Learn more about broccoli extensibility
https://www.youtube.com/watch?v=h-dy5tHm2TA
@CALIGOANIMUS
THANKS!

More Related Content

What's hot

Chromium Embedded Framework + Go at Brooklyn JS
Chromium Embedded Framework + Go at Brooklyn JSChromium Embedded Framework + Go at Brooklyn JS
Chromium Embedded Framework + Go at Brooklyn JSquirkey
 
Vue js 大型專案架構
Vue js 大型專案架構Vue js 大型專案架構
Vue js 大型專案架構Hina Chen
 
How AngularDart & Firebase did an App together
How AngularDart & Firebase did an App togetherHow AngularDart & Firebase did an App together
How AngularDart & Firebase did an App togetherJana Moudrá
 
Introduction to Express and Grunt
Introduction to Express and GruntIntroduction to Express and Grunt
Introduction to Express and GruntPeter deHaan
 
第一次用 Vue.js 就愛上 [改]
第一次用 Vue.js 就愛上 [改]第一次用 Vue.js 就愛上 [改]
第一次用 Vue.js 就愛上 [改]Kuro Hsu
 
What makes me "Grunt"?
What makes me "Grunt"? What makes me "Grunt"?
What makes me "Grunt"? Fabien Doiron
 
Production Ready Javascript With Grunt
Production Ready Javascript With GruntProduction Ready Javascript With Grunt
Production Ready Javascript With GruntXB Software, Ltd.
 
Intro to go web assembly
Intro to go web assemblyIntro to go web assembly
Intro to go web assemblyChe-Chia Chang
 
以Vue開發電子商務網站
架構與眉角
以Vue開發電子商務網站
架構與眉角以Vue開發電子商務網站
架構與眉角
以Vue開發電子商務網站
架構與眉角Mei-yu Chen
 
Bs webgl소모임004
Bs webgl소모임004Bs webgl소모임004
Bs webgl소모임004Seonki Paik
 
Drive chrome(headless) with puppeteer
Drive chrome(headless) with puppeteerDrive chrome(headless) with puppeteer
Drive chrome(headless) with puppeteerVodqaBLR
 
SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...
SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...
SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...South Tyrol Free Software Conference
 
Bower - A package manager for the web
Bower - A package manager for the webBower - A package manager for the web
Bower - A package manager for the webLarry Nung
 
XPDDS18: A dive into kbuild - Cao jin, Fujitsu
XPDDS18: A dive into kbuild - Cao jin, FujitsuXPDDS18: A dive into kbuild - Cao jin, Fujitsu
XPDDS18: A dive into kbuild - Cao jin, FujitsuThe Linux Foundation
 
Running node.js as a service behind nginx/varnish
Running node.js as a service behind nginx/varnishRunning node.js as a service behind nginx/varnish
Running node.js as a service behind nginx/varnishthiagoalessio
 
How to build a Dart and Firebase app in 30 mins
How to build a Dart and Firebase app in 30 minsHow to build a Dart and Firebase app in 30 mins
How to build a Dart and Firebase app in 30 minsJana Moudrá
 
Puppeteer - Headless Chrome Node API
Puppeteer - Headless Chrome Node APIPuppeteer - Headless Chrome Node API
Puppeteer - Headless Chrome Node APIWilson Su
 
Dev chrome tools tips and tricks
Dev chrome tools tips and tricksDev chrome tools tips and tricks
Dev chrome tools tips and tricksOuijden Dhemaid
 

What's hot (20)

Chromium Embedded Framework + Go at Brooklyn JS
Chromium Embedded Framework + Go at Brooklyn JSChromium Embedded Framework + Go at Brooklyn JS
Chromium Embedded Framework + Go at Brooklyn JS
 
Vue js 大型專案架構
Vue js 大型專案架構Vue js 大型專案架構
Vue js 大型專案架構
 
How AngularDart & Firebase did an App together
How AngularDart & Firebase did an App togetherHow AngularDart & Firebase did an App together
How AngularDart & Firebase did an App together
 
Introduction to Express and Grunt
Introduction to Express and GruntIntroduction to Express and Grunt
Introduction to Express and Grunt
 
MAGA - PUG Roma giugno 2017
MAGA - PUG Roma giugno 2017MAGA - PUG Roma giugno 2017
MAGA - PUG Roma giugno 2017
 
第一次用 Vue.js 就愛上 [改]
第一次用 Vue.js 就愛上 [改]第一次用 Vue.js 就愛上 [改]
第一次用 Vue.js 就愛上 [改]
 
What makes me "Grunt"?
What makes me "Grunt"? What makes me "Grunt"?
What makes me "Grunt"?
 
Production Ready Javascript With Grunt
Production Ready Javascript With GruntProduction Ready Javascript With Grunt
Production Ready Javascript With Grunt
 
Intro to go web assembly
Intro to go web assemblyIntro to go web assembly
Intro to go web assembly
 
以Vue開發電子商務網站
架構與眉角
以Vue開發電子商務網站
架構與眉角以Vue開發電子商務網站
架構與眉角
以Vue開發電子商務網站
架構與眉角
 
Bs webgl소모임004
Bs webgl소모임004Bs webgl소모임004
Bs webgl소모임004
 
Drive chrome(headless) with puppeteer
Drive chrome(headless) with puppeteerDrive chrome(headless) with puppeteer
Drive chrome(headless) with puppeteer
 
Grunt and Bower
Grunt and BowerGrunt and Bower
Grunt and Bower
 
SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...
SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...
SFScon17 - Paolo D'Incau: "Build, test and release your software using Free S...
 
Bower - A package manager for the web
Bower - A package manager for the webBower - A package manager for the web
Bower - A package manager for the web
 
XPDDS18: A dive into kbuild - Cao jin, Fujitsu
XPDDS18: A dive into kbuild - Cao jin, FujitsuXPDDS18: A dive into kbuild - Cao jin, Fujitsu
XPDDS18: A dive into kbuild - Cao jin, Fujitsu
 
Running node.js as a service behind nginx/varnish
Running node.js as a service behind nginx/varnishRunning node.js as a service behind nginx/varnish
Running node.js as a service behind nginx/varnish
 
How to build a Dart and Firebase app in 30 mins
How to build a Dart and Firebase app in 30 minsHow to build a Dart and Firebase app in 30 mins
How to build a Dart and Firebase app in 30 mins
 
Puppeteer - Headless Chrome Node API
Puppeteer - Headless Chrome Node APIPuppeteer - Headless Chrome Node API
Puppeteer - Headless Chrome Node API
 
Dev chrome tools tips and tricks
Dev chrome tools tips and tricksDev chrome tools tips and tricks
Dev chrome tools tips and tricks
 

Similar to Broccoli Lightning Talk - September 2016

How to Webpack your Django!
How to Webpack your Django!How to Webpack your Django!
How to Webpack your Django!David Gibbons
 
using Mithril.js + postgREST to build and consume API's
using Mithril.js + postgREST to build and consume API'susing Mithril.js + postgREST to build and consume API's
using Mithril.js + postgREST to build and consume API'sAntônio Roberto Silva
 
Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...
Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...
Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...Codemotion
 
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...Luciano Mammino
 
ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...
ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...
ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...Gavin Pickin
 
Let's play with adf 3.0
Let's play with adf 3.0Let's play with adf 3.0
Let's play with adf 3.0Eugenio Romano
 
Node Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.jsNode Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.jsChris Bailey
 
Full Angular 7 Firebase Authentication System
Full Angular 7 Firebase Authentication SystemFull Angular 7 Firebase Authentication System
Full Angular 7 Firebase Authentication SystemDigamber Singh
 
Desbravando Web Components
Desbravando Web ComponentsDesbravando Web Components
Desbravando Web ComponentsMateus Ortiz
 
Predictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and ReduxPredictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and ReduxFITC
 
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...Ortus Solutions, Corp
 
Vuejs for Angular developers
Vuejs for Angular developersVuejs for Angular developers
Vuejs for Angular developersMikhail Kuznetcov
 
Django + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar DjangoDjango + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar DjangoJavier Abadía
 
London Node.js User Group - Cloud-native Node.js
London Node.js User Group - Cloud-native Node.jsLondon Node.js User Group - Cloud-native Node.js
London Node.js User Group - Cloud-native Node.jsBethany Nicolle Griggs
 
Vue routing tutorial getting started with vue router
Vue routing tutorial getting started with vue routerVue routing tutorial getting started with vue router
Vue routing tutorial getting started with vue routerKaty Slemon
 
Mobile App Development: Primi passi con NativeScript e Angular 2
Mobile App Development: Primi passi con NativeScript e Angular 2Mobile App Development: Primi passi con NativeScript e Angular 2
Mobile App Development: Primi passi con NativeScript e Angular 2Filippo Matteo Riggio
 
How to Implement Micro Frontend Architecture using Angular Framework
How to Implement Micro Frontend Architecture using Angular FrameworkHow to Implement Micro Frontend Architecture using Angular Framework
How to Implement Micro Frontend Architecture using Angular FrameworkRapidValue
 
Pyramid Lighter/Faster/Better web apps
Pyramid Lighter/Faster/Better web appsPyramid Lighter/Faster/Better web apps
Pyramid Lighter/Faster/Better web appsDylan Jay
 

Similar to Broccoli Lightning Talk - September 2016 (20)

How to Webpack your Django!
How to Webpack your Django!How to Webpack your Django!
How to Webpack your Django!
 
using Mithril.js + postgREST to build and consume API's
using Mithril.js + postgREST to build and consume API'susing Mithril.js + postgREST to build and consume API's
using Mithril.js + postgREST to build and consume API's
 
Love at first Vue
Love at first VueLove at first Vue
Love at first Vue
 
Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...
Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...
Universal JavaScript Web Applications with React - Luciano Mammino - Codemoti...
 
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...
 
ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...
ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...
ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 VueJS cod...
 
Let's play with adf 3.0
Let's play with adf 3.0Let's play with adf 3.0
Let's play with adf 3.0
 
Node Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.jsNode Summit 2018: Cloud Native Node.js
Node Summit 2018: Cloud Native Node.js
 
Full Angular 7 Firebase Authentication System
Full Angular 7 Firebase Authentication SystemFull Angular 7 Firebase Authentication System
Full Angular 7 Firebase Authentication System
 
Desbravando Web Components
Desbravando Web ComponentsDesbravando Web Components
Desbravando Web Components
 
Predictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and ReduxPredictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and Redux
 
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
 
Vuejs for Angular developers
Vuejs for Angular developersVuejs for Angular developers
Vuejs for Angular developers
 
Django + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar DjangoDjango + Vue, JavaScript de 3ª generación para modernizar Django
Django + Vue, JavaScript de 3ª generación para modernizar Django
 
London Node.js User Group - Cloud-native Node.js
London Node.js User Group - Cloud-native Node.jsLondon Node.js User Group - Cloud-native Node.js
London Node.js User Group - Cloud-native Node.js
 
Introduction to AngularJS
Introduction to AngularJSIntroduction to AngularJS
Introduction to AngularJS
 
Vue routing tutorial getting started with vue router
Vue routing tutorial getting started with vue routerVue routing tutorial getting started with vue router
Vue routing tutorial getting started with vue router
 
Mobile App Development: Primi passi con NativeScript e Angular 2
Mobile App Development: Primi passi con NativeScript e Angular 2Mobile App Development: Primi passi con NativeScript e Angular 2
Mobile App Development: Primi passi con NativeScript e Angular 2
 
How to Implement Micro Frontend Architecture using Angular Framework
How to Implement Micro Frontend Architecture using Angular FrameworkHow to Implement Micro Frontend Architecture using Angular Framework
How to Implement Micro Frontend Architecture using Angular Framework
 
Pyramid Lighter/Faster/Better web apps
Pyramid Lighter/Faster/Better web appsPyramid Lighter/Faster/Better web apps
Pyramid Lighter/Faster/Better web apps
 

Recently uploaded

08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 

Recently uploaded (20)

08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 

Broccoli Lightning Talk - September 2016

  • 3. WAT? Fast build pipeline from Ember that you can use without Ember BROCCOLI
  • 4. WAT? Composable plugin system Highly performant with sub-second speeds Easy to setup and use in a new project BROCCOLI
  • 5. HOW? Given the above project structure… . +-- app | +-- css | +-- js | +-- img | +-- index.html +-- node_modules/ +-- .gitignore +-- Brocfile.js +-- README.md +-- package.json BROCCOLI
  • 6. . +-- app | +-- css | +-- js | +-- img | +-- index.html +-- node_modules/ +-- .gitignore +-- Brocfile.js +-- README.md +-- package.json HOW? We want to bundle all this stuff and provide it to the end user BROCCOLI
  • 7. HOW? $> npm install -g broccoli-cli $> npm install --save-dev broccoli BROCCOLI
  • 8. HOW? $> npm i --save-dev broccoli-concat $> npm i --save-dev broccoli-merge-trees $> npm i --save-dev broccoli-static-compiler $> npm i --save-dev broccoli-uglify-js BROCCOLI
  • 10. . +-- app | +-- css | +-- js | +-- img | +-- index.html +-- node_modules/ +-- .gitignore +-- Brocfile.js +-- README.md +-- package.json HOW? pick this directly BROCCOLI
  • 11. HOW? const pickFiles = require(‘broccoli-static-compiler'); const mergeTrees = require('broccoli-merge-trees'); const app = 'app'; let appHTML = pickFiles(app, { srcDir: '/', files: ['index.html'], destDir: '/' }); module.exports = mergeTrees([appHTML]); BROCCOLI
  • 12. . +-- app | +-- css | +-- js | +-- img | +-- index.html +-- node_modules/ +-- .gitignore +-- Brocfile.js +-- README.md +-- package.json HOW? pick this directly too BROCCOLI
  • 13. HOW? const pickFiles = require(‘broccoli-static-compiler'); const mergeTrees = require('broccoli-merge-trees'); const app = 'app'; let appHTML = pickFiles(app, { srcDir: '/', files: ['index.html'], destDir: '/' }); let appImages = pickFiles(app, { srcDir: '/img', files: ['**/*'], destDir: '/img' }); module.exports = mergeTrees([appHTML, appImages]); BROCCOLI
  • 14. . +-- app | +-- css | +-- js | +-- img | +-- index.html +-- node_modules/ +-- .gitignore +-- Brocfile.js +-- README.md +-- package.json HOW? put ‘em together and uglify BROCCOLI
  • 15. HOW? const pickFiles = require(‘broccoli-static-compiler’); const mergeTrees = require('broccoli-merge-trees'); const concatenate = require(‘broccoli-concat'); const uglifyJS = require('broccoli-uglify-js'); // … let appJS = concatenate(app, { inputFiles: ['js/**/*.js'], outputFile: '/app.js' }); appJS = uglifyJS(appJS, { compress: true }); module.exports = mergeTrees([appHTML, appImages, appJS]); BROCCOLI
  • 16. . +-- app | +-- css | +-- js | +-- img | +-- index.html +-- node_modules/ +-- .gitignore +-- Brocfile.js +-- README.md +-- package.json HOW? put ‘em together BROCCOLI
  • 17. HOW? const pickFiles = require(‘broccoli-static-compiler’); const mergeTrees = require('broccoli-merge-trees'); const concatenate = require(‘broccoli-concat'); const uglifyJS = require('broccoli-uglify-js'); // … let appCSS = concatenate(app, { inputFiles: ['css/**/*.css'], outputFile: '/app.css' }); module.exports = mergeTrees([appHTML, appImages, appJS, appCSS]); BROCCOLI
  • 18. HOW?$> broccoli serve Serving on http://localhost:4200 Slowest Trees | Total ----------------------------------------------+--------------------- SourceMapConcat | 16ms UglifyJSFilter | 11ms BroccoliMergeTrees | 11ms StaticCompiler | 6ms SimpleConcat | 3ms StaticCompiler | 3ms Slowest Trees (cumulative) | Total (avg) ----------------------------------------------+--------------------- SourceMapConcat (1) | 16ms UglifyJSFilter (1) | 11ms BroccoliMergeTrees (1) | 11ms StaticCompiler (2) | 9ms (4 ms) SimpleConcat (1) | 3ms Built - 55 ms @ Fri Sep 02 2016 16:01:26 GMT-0400 (EDT) BROCCOLI
  • 19. HOW? $> broccoli build 'dist' BROCCOLI
  • 21. NOW WHUT?BROCCOLI Transpile ES6 modules with Babel https://github.com/givanse/broccoli-babel-examples Add live-reloading https://github.com/stfsy/broccoli-livereload Learn more about broccoli extensibility https://www.youtube.com/watch?v=h-dy5tHm2TA