SlideShare ist ein Scribd-Unternehmen logo
1 von 25
Intro to Gatsby.js
Ben McCormick
Windsor Circle
Twitter: @ben336
Blog: http://benmccormick.org
Who Am I?
• Senior Software Engineer at Windsor Circle
in Durham
• Blogger at benmccormick.org
• Gatsby user since Fall 2016
So What Is Gatsby?
A new static site generator built with React,
Webpack and GraphQL
What is Gatsby For?
• Building lightning fast websites, especially when
some of the content is relatively static
• Blogs, Business sites, Marketing Sites,
eCommerce sites, web apps
Buzzword #1:
Static Site Generators
• Code executed and HTML generated at build
time
• Typically generated based on a mix of data files
(markdown, images, JSON, ???) templates and
code
• Examples: Jekyll, Hugo,
Buzzword
def: a word or phrase, often an
item of jargon, that is fashionable
at a particular time or in a
particular context.
from https://www.staticgen.com/
Wordpress Model
Wordpress runs
on a server
with content
in a database
User makes
a request
Wordpress runs
PHP code to
pull data from DB
load it into a
template, and then
return HTML
SSG Model
SSG builds a
combination of
data + code into
HTML files
HTML is deployed
to a host
User makes request
and gets static
HTML response
<HTML>
<HTML>
???
SSG Model (Gatsby
Version)
from https://www.gatsbyjs.org
Benefits of SSGs (static
content)
• Fast to load
• Simpler, especially for security
• Cheap to run
• Reliably cacheable
Benefits of SSGs
(dynamic/hybrid content)
• Faster first load
• Progressive Enhancement - we can fall back to
plain HTML by default
• For JS based SSGs- can reuse client and server
code
Buzzword #2: React
• JavaScript framework created by Facebook
• Component-based workflow
• Can be rendered to HTML on the server then “re-
hydrated” on the client
• Immensely popular, large eco-system
• Works with JSX “templating language”
Buzzword #3:Webpack
• JavaScript code bundling tool
• Supports code-splitting (load only what you need for a
specific page, then load more later when its needed
without a full reload)
• Large ecosystem of plugins to handle all sorts of file
types
• Hot Reloading: See changes as you update your code
from https://webpack.js.org/
Buzzword #4: GraphQL
• Data querying language developed by Facebook
• Makes it simple to load all the data needed for a
specific component and ONLY that data
• Young tool, but popular in the React ecosystem
• Comes with a built in playground environment
GraphQL
Benefits of Gatsby
• Optimized loads: Load only what you need for initial
page, then only load new data for additional pages
• Best Practices as plugins: Offline support, image
optimization, RSS feed, etc
• Flexibility of a React web application
• Hot Reloading: See changes as you develop your site
Demo: benmccormick.org
• My blog
• Converted to Gatsby 1 this month (still some
mess)
• https://github.com/benmccormick/benmccormick
org
Gatsby Cons
• Young Project
• Learning curve if you’re not in the
React/Webpack/GraphQL ecosystem
Still Early Days
• Repo opened 2 years ago, full time developed for
the past year, 1.0 released this month
• Some documentation is missing, some trial and
error may be required
• Growing fast
Resources
• Site: https://www.gatsbyjs.org/
• Github: https://github.com/gatsbyjs/gatsby
Questions?
Ben McCormick
Windsor Circle
Twitter: @ben336
Blog: http://benmccormick.org

Weitere ähnliche Inhalte

Was ist angesagt?

Introduction to Nginx
Introduction to NginxIntroduction to Nginx
Introduction to NginxKnoldus Inc.
 
Intro to HTML & CSS
Intro to HTML & CSSIntro to HTML & CSS
Intro to HTML & CSSSyed Sami
 
Introduction to react_js
Introduction to react_jsIntroduction to react_js
Introduction to react_jsMicroPyramid .
 
React + Redux Introduction
React + Redux IntroductionReact + Redux Introduction
React + Redux IntroductionNikolaus Graf
 
Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012
Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012
Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012Treasure Data, Inc.
 
AEM Best Practices for Component Development
AEM Best Practices for Component DevelopmentAEM Best Practices for Component Development
AEM Best Practices for Component DevelopmentGabriel Walt
 
What is component in reactjs
What is component in reactjsWhat is component in reactjs
What is component in reactjsmanojbkalla
 
Html,javascript & css
Html,javascript & cssHtml,javascript & css
Html,javascript & cssPredhin Sapru
 
AEM (CQ) Dispatcher Security and CDN+Browser Caching
AEM (CQ) Dispatcher Security and CDN+Browser CachingAEM (CQ) Dispatcher Security and CDN+Browser Caching
AEM (CQ) Dispatcher Security and CDN+Browser CachingAndrew Khoury
 
[Final] ReactJS presentation
[Final] ReactJS presentation[Final] ReactJS presentation
[Final] ReactJS presentation洪 鹏发
 
Angular - Chapter 1 - Introduction
 Angular - Chapter 1 - Introduction Angular - Chapter 1 - Introduction
Angular - Chapter 1 - IntroductionWebStackAcademy
 

Was ist angesagt? (20)

reactJS
reactJSreactJS
reactJS
 
Web Development
Web DevelopmentWeb Development
Web Development
 
Css
CssCss
Css
 
Introduction to Nginx
Introduction to NginxIntroduction to Nginx
Introduction to Nginx
 
Bootstrap Framework
Bootstrap Framework Bootstrap Framework
Bootstrap Framework
 
Intro to HTML & CSS
Intro to HTML & CSSIntro to HTML & CSS
Intro to HTML & CSS
 
Introduction to react_js
Introduction to react_jsIntroduction to react_js
Introduction to react_js
 
React js for beginners
React js for beginnersReact js for beginners
React js for beginners
 
Dom
DomDom
Dom
 
React + Redux Introduction
React + Redux IntroductionReact + Redux Introduction
React + Redux Introduction
 
Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012
Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012
Fluentd loves MongoDB, at MongoDB SV User Group, July 17, 2012
 
AEM Best Practices for Component Development
AEM Best Practices for Component DevelopmentAEM Best Practices for Component Development
AEM Best Practices for Component Development
 
React workshop
React workshopReact workshop
React workshop
 
What is component in reactjs
What is component in reactjsWhat is component in reactjs
What is component in reactjs
 
Logstash
LogstashLogstash
Logstash
 
Html,javascript & css
Html,javascript & cssHtml,javascript & css
Html,javascript & css
 
AEM (CQ) Dispatcher Security and CDN+Browser Caching
AEM (CQ) Dispatcher Security and CDN+Browser CachingAEM (CQ) Dispatcher Security and CDN+Browser Caching
AEM (CQ) Dispatcher Security and CDN+Browser Caching
 
Ajax and Jquery
Ajax and JqueryAjax and Jquery
Ajax and Jquery
 
[Final] ReactJS presentation
[Final] ReactJS presentation[Final] ReactJS presentation
[Final] ReactJS presentation
 
Angular - Chapter 1 - Introduction
 Angular - Chapter 1 - Introduction Angular - Chapter 1 - Introduction
Angular - Chapter 1 - Introduction
 

Ähnlich wie Intro to Gatsby.js: A Static Site Generator Built with React

JavaScript Service Worker Design Patterns for Better User Experience
JavaScript Service Worker Design Patterns for Better User ExperienceJavaScript Service Worker Design Patterns for Better User Experience
JavaScript Service Worker Design Patterns for Better User Experiencereeder29
 
Webpack and Web Performance Optimization
Webpack and Web Performance OptimizationWebpack and Web Performance Optimization
Webpack and Web Performance OptimizationChen-Tien Tsai
 
Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)
Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)
Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)Zach Lendon
 
MidwestJS 2014 Reconciling ReactJS as a View Layer Replacement
MidwestJS 2014 Reconciling ReactJS as a View Layer ReplacementMidwestJS 2014 Reconciling ReactJS as a View Layer Replacement
MidwestJS 2014 Reconciling ReactJS as a View Layer ReplacementZach Lendon
 
Bundle your modules with Webpack
Bundle your modules with WebpackBundle your modules with Webpack
Bundle your modules with WebpackJake Peyser
 
Untangling spring week5
Untangling spring week5Untangling spring week5
Untangling spring week5Derek Jacoby
 
Mobile Hybrid Development with WordPress
Mobile Hybrid Development with WordPressMobile Hybrid Development with WordPress
Mobile Hybrid Development with WordPressDanilo Ercoli
 
GeneralMobile Hybrid Development with WordPress
GeneralMobile Hybrid Development with WordPressGeneralMobile Hybrid Development with WordPress
GeneralMobile Hybrid Development with WordPressGGDBologna
 
The Dark Side of Single Page Applications
The Dark Side of Single Page ApplicationsThe Dark Side of Single Page Applications
The Dark Side of Single Page ApplicationsDor Kalev
 
Using WordPress for leading local newspaper websites
Using WordPress for leading local newspaper websitesUsing WordPress for leading local newspaper websites
Using WordPress for leading local newspaper websitesChristoph Daum
 
Mongo and node mongo dc 2011
Mongo and node mongo dc 2011Mongo and node mongo dc 2011
Mongo and node mongo dc 2011async_io
 
Static Site Generators - Developing Websites in Low-resource Condition
Static Site Generators - Developing Websites in Low-resource ConditionStatic Site Generators - Developing Websites in Low-resource Condition
Static Site Generators - Developing Websites in Low-resource ConditionIWMW
 
Did wordpressdothat
Did wordpressdothatDid wordpressdothat
Did wordpressdothatJon Bishop
 
Wordpress beyond blogging
Wordpress beyond bloggingWordpress beyond blogging
Wordpress beyond bloggingJulien Minguely
 
Urbanesia - Development History
Urbanesia - Development HistoryUrbanesia - Development History
Urbanesia - Development HistoryBatista Harahap
 
Rise and Fall of the Frontend Developer
Rise and Fall of the Frontend DeveloperRise and Fall of the Frontend Developer
Rise and Fall of the Frontend DeveloperRafael Casuso Romate
 
SharePoint Framework, React, and Office UI sps Silicon Valley
SharePoint Framework, React, and Office UI sps Silicon ValleySharePoint Framework, React, and Office UI sps Silicon Valley
SharePoint Framework, React, and Office UI sps Silicon ValleySonja Madsen
 

Ähnlich wie Intro to Gatsby.js: A Static Site Generator Built with React (20)

JavaScript Service Worker Design Patterns for Better User Experience
JavaScript Service Worker Design Patterns for Better User ExperienceJavaScript Service Worker Design Patterns for Better User Experience
JavaScript Service Worker Design Patterns for Better User Experience
 
ITT Flisol 2013
ITT Flisol 2013ITT Flisol 2013
ITT Flisol 2013
 
Webpack and Web Performance Optimization
Webpack and Web Performance OptimizationWebpack and Web Performance Optimization
Webpack and Web Performance Optimization
 
Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)
Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)
Reconciling ReactJS as a View Layer Replacement (MidwestJS 2014)
 
MidwestJS 2014 Reconciling ReactJS as a View Layer Replacement
MidwestJS 2014 Reconciling ReactJS as a View Layer ReplacementMidwestJS 2014 Reconciling ReactJS as a View Layer Replacement
MidwestJS 2014 Reconciling ReactJS as a View Layer Replacement
 
Bundle your modules with Webpack
Bundle your modules with WebpackBundle your modules with Webpack
Bundle your modules with Webpack
 
Untangling spring week5
Untangling spring week5Untangling spring week5
Untangling spring week5
 
Mobile Hybrid Development with WordPress
Mobile Hybrid Development with WordPressMobile Hybrid Development with WordPress
Mobile Hybrid Development with WordPress
 
GeneralMobile Hybrid Development with WordPress
GeneralMobile Hybrid Development with WordPressGeneralMobile Hybrid Development with WordPress
GeneralMobile Hybrid Development with WordPress
 
The Dark Side of Single Page Applications
The Dark Side of Single Page ApplicationsThe Dark Side of Single Page Applications
The Dark Side of Single Page Applications
 
Using WordPress for leading local newspaper websites
Using WordPress for leading local newspaper websitesUsing WordPress for leading local newspaper websites
Using WordPress for leading local newspaper websites
 
React.js at Cortex
React.js at CortexReact.js at Cortex
React.js at Cortex
 
Mongo and node mongo dc 2011
Mongo and node mongo dc 2011Mongo and node mongo dc 2011
Mongo and node mongo dc 2011
 
Static Site Generators - Developing Websites in Low-resource Condition
Static Site Generators - Developing Websites in Low-resource ConditionStatic Site Generators - Developing Websites in Low-resource Condition
Static Site Generators - Developing Websites in Low-resource Condition
 
Did wordpressdothat
Did wordpressdothatDid wordpressdothat
Did wordpressdothat
 
React Tech Salon
React Tech SalonReact Tech Salon
React Tech Salon
 
Wordpress beyond blogging
Wordpress beyond bloggingWordpress beyond blogging
Wordpress beyond blogging
 
Urbanesia - Development History
Urbanesia - Development HistoryUrbanesia - Development History
Urbanesia - Development History
 
Rise and Fall of the Frontend Developer
Rise and Fall of the Frontend DeveloperRise and Fall of the Frontend Developer
Rise and Fall of the Frontend Developer
 
SharePoint Framework, React, and Office UI sps Silicon Valley
SharePoint Framework, React, and Office UI sps Silicon ValleySharePoint Framework, React, and Office UI sps Silicon Valley
SharePoint Framework, React, and Office UI sps Silicon Valley
 

Mehr von Ben McCormick

A Second Set Of Eyes: Getting The Most From Code Reviews
A Second Set Of Eyes: Getting The Most From Code ReviewsA Second Set Of Eyes: Getting The Most From Code Reviews
A Second Set Of Eyes: Getting The Most From Code ReviewsBen McCormick
 
Saving Time By Testing With Jest
Saving Time By Testing With JestSaving Time By Testing With Jest
Saving Time By Testing With JestBen McCormick
 
Decorators Lightning Talk for Triangle JavaScript
Decorators Lightning Talk for Triangle JavaScriptDecorators Lightning Talk for Triangle JavaScript
Decorators Lightning Talk for Triangle JavaScriptBen McCormick
 
Component Based Development
Component Based DevelopmentComponent Based Development
Component Based DevelopmentBen McCormick
 

Mehr von Ben McCormick (6)

A Second Set Of Eyes: Getting The Most From Code Reviews
A Second Set Of Eyes: Getting The Most From Code ReviewsA Second Set Of Eyes: Getting The Most From Code Reviews
A Second Set Of Eyes: Getting The Most From Code Reviews
 
Saving Time By Testing With Jest
Saving Time By Testing With JestSaving Time By Testing With Jest
Saving Time By Testing With Jest
 
Vim survival guide
Vim survival guideVim survival guide
Vim survival guide
 
Decorators Lightning Talk for Triangle JavaScript
Decorators Lightning Talk for Triangle JavaScriptDecorators Lightning Talk for Triangle JavaScript
Decorators Lightning Talk for Triangle JavaScript
 
Backbonemeetup
BackbonemeetupBackbonemeetup
Backbonemeetup
 
Component Based Development
Component Based DevelopmentComponent Based Development
Component Based Development
 

Kürzlich hochgeladen

Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about usDynamic Netsoft
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsArshad QA
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️anilsa9823
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfjoe51371421
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AIABDERRAOUF MEHENNI
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number SystemsJheuzeDellosa
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 

Kürzlich hochgeladen (20)

Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about us
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online  ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
 
Exploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the ProcessExploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the Process
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdf
 
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AISyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number Systems
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 

Intro to Gatsby.js: A Static Site Generator Built with React

  • 1. Intro to Gatsby.js Ben McCormick Windsor Circle Twitter: @ben336 Blog: http://benmccormick.org
  • 2. Who Am I? • Senior Software Engineer at Windsor Circle in Durham • Blogger at benmccormick.org • Gatsby user since Fall 2016
  • 3. So What Is Gatsby? A new static site generator built with React, Webpack and GraphQL
  • 4. What is Gatsby For? • Building lightning fast websites, especially when some of the content is relatively static • Blogs, Business sites, Marketing Sites, eCommerce sites, web apps
  • 5. Buzzword #1: Static Site Generators • Code executed and HTML generated at build time • Typically generated based on a mix of data files (markdown, images, JSON, ???) templates and code • Examples: Jekyll, Hugo,
  • 6. Buzzword def: a word or phrase, often an item of jargon, that is fashionable at a particular time or in a particular context.
  • 8. Wordpress Model Wordpress runs on a server with content in a database User makes a request Wordpress runs PHP code to pull data from DB load it into a template, and then return HTML
  • 9. SSG Model SSG builds a combination of data + code into HTML files HTML is deployed to a host User makes request and gets static HTML response <HTML> <HTML> ???
  • 10. SSG Model (Gatsby Version) from https://www.gatsbyjs.org
  • 11. Benefits of SSGs (static content) • Fast to load • Simpler, especially for security • Cheap to run • Reliably cacheable
  • 12. Benefits of SSGs (dynamic/hybrid content) • Faster first load • Progressive Enhancement - we can fall back to plain HTML by default • For JS based SSGs- can reuse client and server code
  • 13. Buzzword #2: React • JavaScript framework created by Facebook • Component-based workflow • Can be rendered to HTML on the server then “re- hydrated” on the client • Immensely popular, large eco-system • Works with JSX “templating language”
  • 14. Buzzword #3:Webpack • JavaScript code bundling tool • Supports code-splitting (load only what you need for a specific page, then load more later when its needed without a full reload) • Large ecosystem of plugins to handle all sorts of file types • Hot Reloading: See changes as you update your code
  • 16. Buzzword #4: GraphQL • Data querying language developed by Facebook • Makes it simple to load all the data needed for a specific component and ONLY that data • Young tool, but popular in the React ecosystem • Comes with a built in playground environment
  • 18. Benefits of Gatsby • Optimized loads: Load only what you need for initial page, then only load new data for additional pages • Best Practices as plugins: Offline support, image optimization, RSS feed, etc • Flexibility of a React web application • Hot Reloading: See changes as you develop your site
  • 19. Demo: benmccormick.org • My blog • Converted to Gatsby 1 this month (still some mess) • https://github.com/benmccormick/benmccormick org
  • 20. Gatsby Cons • Young Project • Learning curve if you’re not in the React/Webpack/GraphQL ecosystem
  • 21. Still Early Days • Repo opened 2 years ago, full time developed for the past year, 1.0 released this month • Some documentation is missing, some trial and error may be required • Growing fast
  • 22.
  • 23. Resources • Site: https://www.gatsbyjs.org/ • Github: https://github.com/gatsbyjs/gatsby
  • 25. Ben McCormick Windsor Circle Twitter: @ben336 Blog: http://benmccormick.org

Hinweis der Redaktion

  1. Hey everybody, I’m the third speaker tonight so hopefully your brains aren’t too full. I’ll try to keep things moving.
  2. Who has already heard about gatsby? Its been around for ~ a year, but just released a revamped 1.0 at the beginning of this month So many buzzwords…
  3. Show Segment Blog
  4. Vs wordpress
  5. VS a monolith web app
  6. Everything is a re-usable component with a clear interface JSX isn’t really a templating language ¯\_(ツ)_/¯
  7. Like a more limited SQL for APIs? Github, Shopify, NYTimes
  8. Query for grabbing all JavaScript related posts from my blog
  9. Compared to other static site generators: It’s about smart data handling and builds Not just for text
  10. Webpack is abstracted away a bit, React and GraphQL are definitely not
  11. There have been a lot of updates this month, and I’ve seen some bugs come through. Documentation looks better for new starters than for upgraders right now Benefit of the structure is that bugs are build time problems not run-time for the most part
  12. Opportunities to contribute