Logo
    Search

    Hasty Treat - Spicy Takeout - PHP Is Good and We’re Just Re-Creating It

    enOctober 04, 2021

    Podcast Summary

    • The Evolution of Web Development: Old Techniques Resurface in New LanguagesStay informed, adapt to new technologies, and recognize the value of the past in web development to succeed.

      The web development landscape is evolving, and we're seeing a resurgence of techniques and technologies that were once popular with languages like PHP, now being recreated in JavaScript. Scott and Wes, the hosts of the Syntax podcast, discussed this topic in their latest episode, jokingly referring to it as a "spicy takeout." They shared their thoughts on the current state of web development, with Scott expressing his recent spicy opinions on React and Svelte. During the episode, they also shared their sponsors, FreshBooks and LogRocket. FreshBooks is a cloud accounting solution for small businesses and freelancers, allowing users to log invoices, send them to clients, and manage expenses. LogRocket, on the other hand, is an error and exception handling service that provides video replay of user sessions, helping developers debug issues more efficiently. As they discussed the evolution of web development, they highlighted the importance of adapting to new technologies and tools while also recognizing the value of the past. They encouraged developers to stay informed and open-minded, as the landscape is constantly changing. In essence, the takeaway is that web development is an ever-evolving field, and it's essential for developers to stay informed, adapt to new technologies, and recognize the value of the past. Whether you're a seasoned developer or just starting out, staying up-to-date with the latest trends and tools is crucial for success.

    • Effective Debugging with LogRocket and the Relevance of PHPLogRocket is a powerful debugging tool that offers insights into user behavior and troubleshoots issues in real-time. PHP and JavaScript share similarities, and PHP continues to be relevant in modern web development.

      LogRocket is a powerful debugging tool that offers features such as a scrubbable video of user interactions, error logs, network requests, and user information. This tool is particularly useful for developers who want to gain insights into user behavior and troubleshoot issues in real-time. The speaker, Wes Bos, also shared his perspective on why PHP, despite its criticisms, continues to be relevant in modern web development. He argued that PHP and JavaScript share similarities, such as the ability to mix template and logic in the same file, and that developers are essentially recreating the best parts of PHP in JavaScript. Bos also mentioned that he has not written PHP code in a long time but appreciates its value. He encouraged listeners to check out LogRocket and offered a 14-day free trial at logrocket.com/forward/syntax. Overall, the discussion highlighted the importance of effective debugging tools and the ongoing evolution of web development technologies.

    • Blurred lines between logic and templating in PHPSome argue for separation, others find mixing logic and templating in PHP more natural and efficient. PHP's invocation-based nature simplifies testing and deployment, and its vast standard library saves time and effort.

      The blurred lines between logic and templating in programming languages like PHP can be a source of controversy and confusion. While some argue that keeping these elements separate is a best practice, others find it more natural and efficient to mix them. This was a topic of debate around a decade ago, and while some saw it as a departure from established programming principles, others saw it as a logical extension for ease and efficiency. Another key point discussed was the invocation-based nature of PHP, which makes it similar to serverless architecture. Each request in PHP has its own scope, and the script runs independently without the need for starting or stopping a server. This makes testing and deployment more straightforward. Lastly, the massive standard library in PHP was highlighted as a significant advantage. From formatting dates to hashing MD5, resizing images, and even audio bindings, PHP offers a wide range of built-in functionalities that can save developers time and effort.

    • PHP and JavaScript Similarities and Differences in Web DevelopmentBoth PHP and JavaScript have unique strengths and similarities in web development, including URL-based routing, server-rendered components, and accessing input variables. However, there are differences to consider, such as naming conventions and security concerns.

      Both PHP and JavaScript have their unique strengths when it comes to web development. While PHP offers an exhaustive list of bindings for various functionalities, JavaScript is starting to match that with a growing standard library. This means developers can rely less on utility libraries for smaller tasks. Another similarity is the URL-based routing, where the script associated with a specific URL is executed. This approach is becoming more popular, but it also comes with security concerns as it could potentially expose unwanted functionality. Another notable trend is the shift towards server-rendered components, with frameworks like Ruby on Rails' Hotwire, React, and SvelteKit embracing this approach. Additionally, accessing GET and POST input variables directly within scripts is becoming more common in frameworks like Next.js and SvelteKit. Despite these similarities, there are differences, such as naming conventions and security concerns, that developers must consider when choosing between these technologies. Overall, understanding these trends and their implications can help developers make informed decisions about which tools to use for their web development projects.

    • Accessing query params in SveltekitIn Sveltekit, you can access query params from a store or the load function and interpolate variables directly into your code for convenience.

      In Sveltekit, you can access query params from a store or the load function. Variable interpolation is also a major convenience in JavaScript, allowing you to interpolate variables wherever you want in your code instead of concatenating strings. All-in-one frameworks like Laravel have been popular for years, offering templating, auth, and database access in one place. While it's possible to write SQL statements directly in templates, it's not common practice due to security concerns. Despite the advantages of PHP, some developers continue to prefer JavaScript for its simplicity and the fact that it requires less context-switching between client and server environments. The reasons why people dislike PHP can vary widely, from personal biases to practical considerations. Ultimately, the choice between PHP and JavaScript depends on the specific needs and preferences of the developer or development team.

    • PHP: Love or Hate, Depends on Experience and ContextPerceptions of PHP are shaped by personal experiences and context. While it had challenges historically, modern versions and frameworks like Laravel have improved its reputation.

      The perception of PHP, both positive and negative, is shaped by personal experiences and the specific context in which one has worked with it. Some developers may dislike PHP due to past difficulties or bad experiences, while others appreciate its features and the community surrounding it. Historically, PHP had its challenges, such as security vulnerabilities and inconsistent APIs. However, modern versions, like PHP 7 and PHP 8, have addressed many of these issues. For instance, PHP 8 introduces full typing, which was previously a criticism. Moreover, the Laravel framework, built on PHP, has a strong community of developers who are passionate about the technology. They don't push their preferences aggressively, making it an attractive choice for many developers. The dislike for PHP might also stem from the early web era when it was extensively used, and its quirks and vulnerabilities were more prevalent. However, as the technology has evolved, so have the opinions about it. In summary, the love or hate relationship with PHP is a complex one, influenced by individual experiences, the specific context, and the evolution of the technology itself.

    • PHP vs JavaScript: Choosing the Right Tool for the JobJavaScript's flexibility and client-side rendering make it popular for modern apps, while PHP's server-side rendering and shared dependencies have their merits. Both have their place, and the choice depends on the specific use case.

      While PHP has its merits, such as the ability to share dependencies and server render components, JavaScript has become the preferred choice for building modern applications due to its flexibility and ability to run in the browser. The speaker emphasizes the benefits of client-side rendering and routing, which allow for easy page transitions and animations without having to reload the entire page. They also mention the importance of sharing types between the server and client and the growing trend of using JavaScript frameworks like Vue.js for server-side rendering. The speaker shares their personal preference for JavaScript and acknowledges that everyone's app is different, with various use cases for both PHP and JavaScript. They also express some reservations about the performance of Hotwire, a new technology for building modern web applications, but invite correction if they are mistaken. Overall, the conversation highlights the ongoing debate between PHP and JavaScript and the importance of choosing the right tool for the job.

    • Experience with Hey Email ServiceDespite appreciating Hey's mission to simplify email, the speaker found the requirement of creating a new email address a turnoff and shared skepticism towards the idea, concluding that there may be challenges in convincing users to adopt a new email platform.

      The speaker shared his experience of trying out Hey email service but ultimately decided against continuing to use it after his free trial expired. He appreciated the concept behind Hey's mission to simplify email management, but he found the idea of having to create a new email address for it less appealing. He made an analogy to using Google Inbox but requiring a separate email account for it, expressing his skepticism towards the idea. The speaker concluded the discussion by thanking the listeners for tuning in and encouraging them to share their thoughts with the Syntax FM team. Overall, the speaker's feedback suggests that while Hey's mission to improve email management is admirable, there may be challenges in convincing users to adopt a new email platform, especially if it requires significant changes to their existing email setup.

    Recent Episodes from Syntax - Tasty Web Development Treats

    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

    Sick Picks

    Shameless Plugs

    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

    789: Do More With AI - LLMs With Big Token Counts

    789: Do More With AI - LLMs With Big Token Counts

    Join Scott and CJ as they dive into the fascinating world of AI, exploring topics from LLM token sizes and context windows to understanding input length. They discuss practical use cases and share insights on how web developers can leverage larger token counts to maximize the potential of AI and LLMs.

    Show Notes

    Hit us up on Socials!

    Syntax: X Instagram Tiktok LinkedIn Threads

    Wes: X Instagram Tiktok LinkedIn Threads

    Scott: X Instagram Tiktok LinkedIn Threads

    CJ: X Instagram YouTube TwitchTV

    Randy: X Instagram YouTube Threads

    788: Supabase: Open Source Firebase for Fullstack JS Apps

    788: Supabase: Open Source Firebase for Fullstack JS Apps

    Scott and CJ chat with Paul Copplestone, CEO and co-founder of Supabase, about the journey of building an open source alternative to Firebase. Learn about the tech stack, the story behind their excellent documentation, and how Supabase balances business goals with open-source values.

    Show Notes

    • 00:00 Welcome to Syntax!
    • 00:30 Who is Paul Copplestone?
    • 01:17 Why ‘Supa’ and not ‘Super’?
    • 02:26 How did Supabase start?
    • 08:42 Simplicity in design.
    • 10:32 How do you take Supabase one step beyond the competition?
    • 12:35 How do you decide which libraries are officially supported vs community maintained?
      • 15:17 You don’t need a client library!
    • 16:48 Edge functions for server-side functionality.
    • 18:51 The genesis of pgvector.
    • 20:59 The product strategy.
    • 22:25 What’s the story behind Supabase’s awesome docs?
    • 25:26 The tech behind Supabase.
    • 35:46 How do you balance business goals with open source?
    • 42:01 What’s next for Supabase?
    • 44:15 Supabase’s GA + new features.
    • 48:24 Who runs the X account?
    • 50:39 Sick Picks + Shameless Plugs.

    Sick Picks

    Shameless Plugs

    Hit us up on Socials!

    Syntax: X Instagram Tiktok LinkedIn Threads

    Wes: X Instagram Tiktok LinkedIn Threads

    Scott: X Instagram Tiktok LinkedIn Threads

    CJ: X Instagram YouTube TwitchTV

    Randy: X Instagram YouTube Threads

    787: You Should Try Vue.js

    787: You Should Try Vue.js

    Scott and CJ dive deep into the world of Vue.js, exploring what makes this frontend framework unique and why it stands out from React and Svelte. CJ gives a comprehensive tour, covering everything from getting started to advanced features like state management and Vue’s built-in styles.

    Show Notes

    Vue.js: The Documentary.

    Sick Picks

    Shameless Plugs

    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

    786: What Open Source license should you use?

    786: What Open Source license should you use?

    Scott and CJ dive into the world of open source, breaking down its meaning, benefits, and the various types of licenses you’ll encounter. From permissive licenses like MIT and Apache 2.0 to copy-left licenses such as GNU GPLv3, they’ll help you choose and apply the right license for your project.

    Show Notes

    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

    785: What’s Next for NextJS with Tim Neutkens

    785: What’s Next for NextJS with Tim Neutkens

    Scott and Wes dive into the world of Next.js with special guest Tim Neutkens from Vercel. They explore the latest updates, including the React Compiler and React Server Components, discussing their impact on developer workflows and the future of Next.js development.

    Show Notes

    • 00:00 Welcome to Syntax!
    • 00:30 What does the React Compiler do?
    • 05:04 Will React Compiler help with managing Context?
    • 06:39 What happens if you’re not using a React Compiler?
    • 09:30 Will this work on any NextJS version?
    • 12:18 What are React Server Components?
    • 16:28 Shipping all the data inside an encapsulated component.
    • 20:17 Clearing up the frustrations around retrofitting server components.
    • 23:13 Handing migration.
    • 28:30 Is this just a fetch request with props?
    • 36:41 How closely are the NextJS and React teams working?
    • 41:53 Will we ever get Async Client Components?
    • 43:52 Async Local Storage API.
    • 45:31 Turbopack.
    • 57:51 Sick Picks & Shameless Plugs.

    Sick Picks

    Shameless Plugs

    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

    784: Logging × Blogging × Testing × Freelancing

    784: Logging × Blogging × Testing × Freelancing

    In this Potluck episode, Scott and Wes tackle listener questions on modern blogging, website environmental impact, and using LangChain with LLMs. They also cover CSS hyphens, unit vs. integration testing, and balancing web development with new parenthood.

    Show Notes

    Sick Picks

    Shameless Plugs

    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

    783: How We Built a Netflix Style “Save for Offline” Feature Into Syntax

    783: How We Built a Netflix Style “Save for Offline” Feature Into Syntax

    Scott and Wes dive into the world of browser caching for audio files, exploring the File System API and the Cache API. They discuss size restrictions across different browsers, how tools like Riverside.fm leverage IndexedDB, and walk through code examples for creating, retrieving, and managing cached audio data.

    Show Notes

    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

    782: The Developer’s Guide To Fonts with Stephen Nixon

    782: The Developer’s Guide To Fonts with Stephen Nixon

    Scott and CJ are joined by Stephen Nixon of ArrowType to delve into the world of fonts and type for developers. They explore the intricacies of font creation, the utility of variable fonts, and offer tips for making visually appealing typography on the web.

    Show Notes

    Sick Picks

    Shameless Plugs

    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

    781: Potluck - The Value of TypeScript × Vue vs Svelte × Leetcode

    781: Potluck - The Value of TypeScript × Vue vs Svelte × Leetcode

    In this potluck episode of Syntax, Scott and CJ serve up a variety of community questions, from the nuances of beginner vs. advanced TypeScript to the pros and cons of SvelteKit. They also discuss falling out of love with React, shipping private packages via NPM, and the eternal struggle of always starting but never finishing projects.

    Show Notes

    Sick Picks

    Shameless Plugs

    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

    Related Episodes

    Episode 42: Paul and Vance

    Episode 42: Paul and Vance

    After a little hiatus Phil and Ben back at it, joined this time by Paul Dragoonis and Vance Lucas.

    Paul does some fairly call stuff, manages the PPI framework and contributes to building the actual PHP.net website, the poor sod. Paul is also the winner in the “PHP developers from the UK who are hard to understand” contest two years running, only beating Phil to the title due to being slightly better at handling his booze.

    Vance works at NetSuite and has open-sourced a bunch of code things, most notably phpdotenv and frisby.

    We all have a little natter, share some of our horror stories from projects including PHP.net, and talk about Phil’s recent blog post about how hard it is to be a famous PHP rockstar guru.

    Episode 61: Dollar Bills Yall - Part 1

    Episode 61: Dollar Bills Yall - Part 1

    Matt Trask and Ben Edmunds are joined by Jason McCreary and Anthony Fox to discuss budgeting and personal finance for developers.

    This episode takes a high level view and focuses on how new developers can make good decisions and avoid common pitfalls that come along with that first “developer money” paycheck.

    We’ll be back for part 2 shortly.

    Links

    Episode 17: Authors Galore, Conferences and Game Changers

    Episode 17: Authors Galore, Conferences and Game Changers

    Cal Evans talks with us about some of the great projects he is (and has) been involved with, including training days, writing books, speaking, organising conferences and a bunch more.

    Seriously, this guy has done a shitload of stuff:

    More relevant links:

    Annoyingly in this episode Google Hangouts decided to keep the focus aimed squarely on Phil for the entire show, instead of following the sound of whoever is talking. Nobody needs that much of Phil’s face so we’re skipping the video in this post. It’s mostly just Phil wandering around, drinking two different drinks at the same time, probably picking his nose a bit, who knows.

    Episode 28: Loosley Coupled Mashup

    Episode 28: Loosley Coupled Mashup

    In this episode, Ben and Phil join forces with Loosely Coupled to talk about Open Source, burn out and briefly discuss their favorite open source projects. Jeff was out of action for a lot of it due to unexpected wifi troubles (in San Francisco of all places) so he sadly did not get to take part as much as he would have liked.

    Questions this time around:

    How do you deal nicely with someone who’s too reliant on you for solving problems and is too quick to ask you rather than figure it out themselves? – TazeTSchnitzel

    How do you guys explain OSS to non tech people? My wife finds it strange that I do work for “free” – Chuck Reeves

    As a contractor, how do you feel about “OSS” clauses (that your work can/will be open sourced) in contracts? – Davey Shafik

    If you aren’t following Jeff and Matt then definitely go and do that:

    The video is less edited than the audio, so download and listen for a slightly shorter and more relevant version.