Gatsby vs Next.js in 2021

Gatsby vs Next.js in 2021

In this episode of Syntax, Scott and Wes talk about Gatsby vs Next. A lot has changed in the last year — what are the differences, and do the recommendations from Syntax 120 still hold true? Sanity - Sponsor Sanity.io is a real-time headless CMS with a fully customizable Content Studio built in React. Get a Sanity powered site up and running in minutes at sanity.io/create. Get an awesome supercharged free developer plan on sanity.io/syntax. Sentry - Sponsor If you want to know what’s happening with your errors, track them with Sentry. Sentry is open-source error tracking that helps developers monitor and fix crashes in real time. Cut your time on error resolution from five hours to five minutes. It works with any language and integrates with dozens of other services. Syntax listeners can get two months for free by visiting Sentry.io and using the coupon code “tastytreat”. Show Notes 03:34 - Server-rendered Both do server rendered Gatsby is gone at build time Next is done at build and on deploy 05:26 - Static generation getStaticProps() getServerSideProps() 08:25 - Re-rendering pages Gatsby can be re-rendered and re-deployed - any CMS lets you do this on only the pages that changed. Gatsby-cloud Next.js has the revalidate flag that will re-render when stale 18:54 - Data management Gatsby has a built in GraphQL API feature with Next.js has nothing - it’s not their problem. Use Apollo, or SWR, React Query, or redux, or whatever you want. 23:16 - Client-side data Neither do anything, next. 26:33 - Dynamic Pages List of 100 shoes, each one gets a page List of four types of shoes: basketball, runners, casual, bowling, etc. List of 10 colors: each color gets its own page. List of 12 sizes, each size gets its own page. Now it gets complicated when you do this: Show me basketball shoes, in red, in size 5 600 pages minimum What about size 6+7? Then you get into having to fetch data on the client side - but all your data is in GraphQL?! The queries are different! Gatsby will get “Hosted GraphQL”: https://twitter.com/kylemathews/status/1252803849775009794 30:41 - Routing Neither do nested routing still Both do folder based wrapper 34:50 - Hosting Anywhere 35:54 - Images Compression/resize Lazy loading SVG Blur up Next 10 released first revision of Next.js image It’s not as good as Gatbsy-image Must specify width and height, whereas gatsby has fixed and fluid Compression No blur up Yes lazy loading both don’t support gifs Gatbsy requires annoying GraphQL query OR another plugin like MDX to do it Not for long! https://twitter.com/ascorbic/status/1320770231657238529 Next.js is just

Avsnitt(973)

797: Drizzle: The TypeScript SQL ORM

797: Drizzle: The TypeScript SQL ORM

Scott and Wes chat with Alex Blokh and Andrew Sherman, the co-founders of Drizzle ORM, about building a modern ORM from the ground up. They dive into the importance of type safety, creating filters with Drizzle, and the differences between Drizzle and other ORMs like Prisma. Show Notes 00:00 Welcome to Syntax! Syntax × Drizzle Swag. 01:15 What is Drizzle? 02:36 The genesis of Drizzle. 04:15 The process of building an ORM. 05:38 ‘100% Type-Safe’ and why that’s not a great goal. 07:50 Who is responsible for writing the complicated TypeScript? 09:40 Is an ORM necessary for anyone working with data? 12:15 Creating a product that fits different complexities. 13:19 Brought to you by Sentry.io. 13:44 Creating filters in Drizzle. Callback-based, or imported. Why? 19:22 Drizzle vs Prisma vs Kysely. 22:45 Are you friendly with Prisma? 23:35 Relational queries. 25:17 Query vs select. 27:42 Maintaining so many different technologies. 30:37 Switching databases. 31:39 Drizzle Studio. Drizzle Studio Syntax Theme. 35:00 Accessing Cloudflare D1 SQLite requires connection through a worker. 37:40 Drizzle Kit. 41:37 Will you ever support MongoDB? 42:10 Supporting PGlite and local data storage landscape. DrizzleORM v0.30.6 release notes. 44:00 Being a developer in Ukraine in 2024. How to support Ukraine: Savelife, United24. 51:07 Drizzle is expanding. 53:50 Sick Picks + Shameless Plugs. Sick Picks Andrew - Smart Swim Goggles. Shameless Plugs Andrew - Savelife, United24. Scott - Syntax × Drizzle Swag. Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

19 Juli 202457min

796: Do We Need JS Frameworks × Are You Over-Engineering? × Webview vs Native

796: Do We Need JS Frameworks × Are You Over-Engineering? × Webview vs Native

Scott and Wes tackle a variety of audience questions, from the nuances of over-engineering to the energy consumption of AI LLMs. They also discuss the pros and cons of monorepos, frameworks, and the ever-important question: Do you really need to learn all the developer tooling? Show Notes 00:00 Welcome to Syntax! 00:41 Brought to you by Sentry.io. 01:07 Challenges around a resume playback function. 05:56 Why use Google Forms for Potluck questions? 07:57 What constitutes over-engineering and how to avoid it. 13:28 Webview vs native component based mobile apps. 18:06 Running and managing monorepos. 20:59 Energy consumption of AI LLMs vs static web content. A guide to LLM inference and performance. From Words to Watts: Benchmarking the Energy Costs of LLM Inference. 25:19 Why do we need frameworks? Frank M Taylor Blog Post. 33:05 Handling ad-blockers blocking Sentry and other tools. Syntax GitHub. 38:25 Creating sites without JavaScript. 42:49 Do I really have to learn all the various developer tooling? Wes Bos Tweet. 44:47 What are the best ways to network and meet other developers? 50:16 Sick Picks & Shameless Plugs. Sick Picks Scott: Tweek App/ Wes: Rain-X Waterless Car Wash. Shameless Plugs Scott: Swag Store. Wes: Audio Player Updates. Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

17 Juli 202458min

795: Hosting Private Fonts on the Edge With Cloudflare

795: Hosting Private Fonts on the Edge With Cloudflare

Scott and Wes dish out the intricacies of hosting private fonts using Cloudflare Pages. They explore the challenges of font security, the benefits of a font server, and the nuances of caching and whitelisting to keep your fonts secure and efficient. Show Notes 00:00 Welcome to Syntax! 01:53 Behind the Code: Brought to you by Sentry.io. 03:12 The problem with hosting fonts. Scott’s Fonts. 05:42 The solution, a font server with Cloudflare Pages. 09:37 Utilizing a Key Value Store. 10:53 Storing a whitelist. 13:42 Why not just use a bucket? Check out the code. 15:24 Should whitelisting be done in JavaScript or cores? 17:23 How do you cache to multiple origins? 18:15 Multiple URLs in an allow origin. 19:17 Font security and foundry challenges. 21:43 Moving Domains on Cloudflare. Check out the font Syntax uses! MD-IO. Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

15 Juli 202424min

794: Prettier JavaScript with Vjeux

794: Prettier JavaScript with Vjeux

Scott and Wes sit down with Vjeux from Meta to dive deep into the origins and evolution of Prettier, the widely-used code formatter. They discuss the challenges faced, the decision-making process behind its features, and what the future holds for this indispensable tool in the developer’s toolkit. Show Notes 00:00 Welcome to Syntax! 01:45 Brought to you by Sentry.io. 02:19 New swag! 03:25 Who is Vjeux? 06:56 Is management the key to successful projects? 08:50 The genesis of Prettier. 12:08 Why other JS formatters didn’t work. 16:56 Focusing on edge-cases. 17:41 The goal for Prettier. Prettier Philosophy. 18:31 Next step, integrations. 19:37 Should you run Prettier on save or commit? 21:34 Does Prettier’s limitations lead to higher adoption? Prettier Config. 25:01 What was the most controversial default setting? 28:14 Does Facebook use semicolons? 29:18 Getting approval to devote 6 months to Prettier. 31:42 Working with Mark Zuckerberg. 32:43 Was there ever consideration to augment ESLint instead? Prettier vs. Linters. 35:34 What are your thoughts on the Rust-based alternatives? 36:44 Prettier’s $10,000 bounty. 39:32 What is the future of Prettier? 44:54 Prettier is available in almost every language. 47:59 Advice for other open-source maintainers. 53:26 Sick Picks & Shameless Plugs. Sick Picks Vjeux: TransformersJS. Shameless Plugs Vjeux: Prettier x Syntax Swag. Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

12 Juli 202455min

793: The Local First Landscape

793: The Local First Landscape

Scott and Wes dive into the local first landscape, exploring the benefits and possibilities of local first apps. They highlight some of their favorite tools and discuss why local first is gaining traction among developers. Show Notes 00:00 Welcome to Syntax! 00:27 Behind the Code: Brought to you by Sentry.io. 01:06 Catch up with Wes and Scott. 03:00 The local first space. Scott’s Blog: The Spectrum of Local First Libraries. Syntax 739: The Lofi Movement. 04:27 Some local first apps we love. Linear. Tweek.so. Superhuman. 05:15 The advantages of local first. 06:07 localfirstweb.dev. 09:21 Triplit. 15:33 Evolu. 22:32 RxDB. 24:08 ElectricSQL. 26:57 Pouchdb. 28:46 TinyBase. 32:08 Replicache. 44:31 PowerSync. 48:21 Sick Picks & Shameless Plugs. Sick Picks Scott: Battery Jump Starter. Wes: Battery Tire Pump. Shameless Plugs Wes: Syntax Swag Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

10 Juli 202453min

792: Perfect Sitemaps for SEO

792: Perfect Sitemaps for SEO

Scott and Wes break down the importance of sitemaps for SEO. They dive into the different file formats, essential fields, and common pitfalls to avoid when creating and submitting your sitemap to search engines. Show Notes 00:00 Welcome to Syntax! New Swag Coming Soon. Tolin.ski. 02:09 Brought to you by Sentry.io. 02:39 Sitemaps. 04:36 Why do you need a sitemap? 06:34 Sitemap file formats. 08:31 Choosing a file format. 09:17 Site map file size limits. 10:32 Fully-qualified URLs. 10:50 Fields and metadata. 10:58 What fields matter for SEO? 14:20 What to avoid in your sitemap? 14:23 Dynamic user pages and account pages. 14:43 Parameter-based URLs. 16:01 Redirects, duplicates or disallowed pages. 16:11 Unlisted pages. 17:07 How do you make a sitemap? 20:06 What to do once you have a sitemap. 20:08 Validation. 20:20 Submit to search engine. Bing Webmaster Tools. Google Search Console. 22:11 Cache them! Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

8 Juli 202423min

791: LLRT The Serverless Runtime w/ Richard Davison

791: LLRT The Serverless Runtime w/ Richard Davison

Scott and Wes chat with Richard Davison from AWS about LLRT, a new runtime tailored specifically for Lambda. They dive into the benefits of using LLRT, challenges with JavaScript in serverless, and why Rust was chosen for its development. Show Notes 00:00 Welcome to Syntax! 01:07 Who is Richard Davison? 05:11 What is LLRT and what’s the motivation for building it? 08:25 AWS Lambda example. 11:20 What makes LLRT specifically tailored to Lambda? 14:55 Brought to you by Sentry.io. 15:22 Node.js in Lambda. 16:00 What are some challenges that people have with JavaScript in serverless? 17:20 Lambda memory configuration. 19:23 Managing cost of compute. 21:29 Simpler and faster than Node, Bun, Dino, but not a replacement. 22:31 The benchmarks. 27:00 Quick.js, the main reason for the performance gains. Fabrice Bellard QuickJS. 28:03 The Quick.js engine. 30:35 What was the reason behind creating Quick.js? 33:46 What made you pick Rust for LLRT? 36:34 Abstractions and the value of speed. 39:08 The JIT Compiler. 42:38 Compile cache. 43:27 De-optimizations. 44:59 Node.js Compat, what to use and avoid with LLRT. GitHub AWS Labs Compatibility Chart. 47:52 Will you target with WinterCG spec? 50:22 Streams API. 52:06 What about WebSockets? 53:10 Is this going to be promoted from a labs project? 54:49 Sick Picks + Shameless Plugs. Sick Picks Richard: QuickJS Engine, JSLinux. Shameless Plugs Richard: Javascript Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

5 Juli 202456min

790: State of JS 2023 Reactions

790: State of JS 2023 Reactions

Scott and Wes dive into the 2023 State of JavaScript survey, breaking down the latest trends and pain points in front-end frameworks, build tools, and JavaScript runtimes. Tune in for their hot takes and insights on what’s shaping the JavaScript landscape this year! Show Notes 00:00 Welcome to Syntax! State of JS 2023. 03:04 Brought to you by Sentry.io. 03:43 New Syntax Swag! Syntax Swag Store. 04:42 Front end frameworks. 08:30 Front end framework pain-points. 12:17 Metaframeworks. 17:45 Metaframework pain-points. 22:17 Build tools. Rolldown. 24:45 Build tool pain-points. 25:54 JavaScript runtimes. 28:19 Edge + serverless runtimes. 29:30 Backend frameworks. 33:17 Non-JavaScript languages. 36:12 Hosting service. 38:50 Usage. 40:05 Javascript usage. 41:03 Missing features. 45:04 Industry sector. 47:37 The awards. 51:34 Sick Picks + Shameless Plugs. Sick Picks Scott: Electric Lighter. Wes: Monkey Noodle. Shameless Plugs Wes: Syntax Swag Store. Hit us up on Socials! Syntax: X Instagram Tiktok LinkedIn Threads Wes: X Instagram Tiktok LinkedIn Threads Scott: X Instagram Tiktok LinkedIn Threads Randy: X Instagram YouTube Threads

3 Juli 202457min

Populärt inom Politik & nyheter

p3-krim
rss-krimstad
svenska-fall
flashback-forever
rss-viva-fotboll
motiv
aftonbladet-daily
rss-sanning-konsekvens
aftonbladet-krim
rss-vad-fan-hande
rss-krimreportrarna
olyckan-inifran
grans
dagens-eko
rss-frandfors-horna
fordomspodden
spar
rss-flodet
blenda-2
politiken