PHPNews

Nordic.js 2017 Recap

Last month I travelled up north to my first JavaScript conference: Nordic.js. The entire conference was a great experience: the speakers, the location, the food ( kanelbullar! ), ... Here's a quick recap of my favorite talks. Ben Schwarz: Beyond the bubble Ben gave a talk about web performance, and how many …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Tuesday October 3, 2017


Introducing Our Company Guidelines Site

We just open sourced our company guidelines site ! We previously kept the contents in a private wiki on GitHub, but I'm glad we finally put the time in giving the contents a real home. Like our docs site , the content is stored in markdown files, which can directly be edited on GitHub . The site deploys whenever …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Monday August 21, 2017


What's in our .babelrc?

A lot has been going in in JavaScript the past few years. One of my favorite things has been the usage of babel , which allows us to write future JavaScript syntax today. The babel ecosystem has tons of plugins and configuration options, I'd like to elaborate on our usage at Spatie . To provide some context on …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Wednesday August 16, 2017


Is Snapshot Testing Viable in PHP?

Christopher Pitt wrote a pretty comprehensive article on one of our latest packages, which is one of my favorite packages I've written at Spatie to date, phpunit-snapshot-assertions. Ah-ha moments are beautiful and rare in programming. Every so often, we’re fortunate enough to discover some trick or facet of a …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Tuesday July 4, 2017


Fragmentation is Fabulous

In a recent Twitter thread, Sebastian McKenzie ( Yarn and Babel author) shared his thoughts on the current state of open source. This tweet stood out for me (and he later ironically dubbed it his "most thoughtleader tweet ever" ): Revel in fragmentation and duplication because without it there's stagnation …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Monday July 3, 2017


TypeScript With Laravel Mix

Since writing this post, TypeScript has become officially supported in Laravel Mix (version 0.12 and up). There's still some informative stuff in here if you're new to TypeScript, but use the official method if you're on a newer version of Mix! In a recent Spatie project we decided to give TypeScript a …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Tuesday May 16, 2017


Non-breaking, SEO Friendly Urls in Laravel

When admins create or update a news item—or any other entity—in our homegrown CMS , a url slug is generated based on it's title. The downside here is that when the title changes, the old url would break. If we wouldn't regenerate the url on updates, edited titles would still have an old slug in the url, which isn't …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Tuesday February 21, 2017


Dealing With Templates in Vue.js 2.0

Vue 2.0 introduced it's own virtual DOM implementation. At first sight, this doesn't seem to have a large effect on the way you write templates. From the docs: Under the hood, Vue compiles the templates into Virtual DOM render functions. Combined with the reactivity system, Vue is able to intelligently figure out …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Wednesday December 21, 2016


Normalize Your Values on Input

Dynamic languages allow us to pass anything as a parameter without requiring a specific type. In turn, this means we often need to handle some extra validation for the data that comes in to our objects. This is a lightweight post on handling your incoming values effectively by normalizing them as soon as possible. …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Wednesday March 9, 2016


Adventure Time With Webpack

Over the past few weeks I've been migrating our asset pipeline at Spatie from Laravel Elixir (a gulp wrapper) to webpack. Between having endless possibilities, the occasional incomplete section in the docs, and the fact that everyone has slightly different needs for their asset pipeline (which makes examples hard), …

Continue reading »

Written by Sebastian De Deyne - - Aggregated on Thursday February 4, 2016