Code with Hugo

Node.js and JavaScript Guides

  • Home
  • Books
  • Node
  • Testing
  • JavaScript
  • More...
  • Search
  • About
  • Gear & Setup
Subscribe
#meta #blogging #technical writing #hugo

6 months of Code with Hugo, in numbers

Going from 0 to small. A developer’s journey starting a technical blog from scratch. Stats in this post as of 21st of October, follow me on Twitter for monthly updates. Contents: ...

  • Hugo Di Francesco
    Author
2 min read
#node #javascript #es6

Use ES modules/ES6 import in Node without Babel/Webpack using `esm`

Node has been implementing more and more ES6+ (ESNext) features natively. One of the features that is taking the longest to implement is modules. The reason for this is that Node and npm run on what is called CommonJS, with which you use require('module-name') to import from othe ...

  • Hugo Di Francesco
    Author
3 min read
#javascript #deployment #observablehq

ObservableHQ notebooks for JavaScript demos and prototypes

ObservableHQ is a platform being built by Mike Bostock (creator of the D3 visualisation library), Jeremy Ashkenas (“Made CoffeeScript, Backbone.js, Underscore and other ragbag” from his Twitter bio) and Tom MacWright (creator of the big presentation framework, simple-statistics a ...

  • Hugo Di Francesco
    Author
4 min read
#javascript #es6 #interview #functional programming

Impress interviewers with recursion in JavaScript with ES6 features

There’s nothing as flashy and useful for JavaScript interviews than recursion. If you just want to be impressive with recursion in JavaScript, here are some semi real-world (technical test type) examples. The short definition of a recursive solution to a problem (in computer sci ...

  • Hugo Di Francesco
    Author
4 min read
#javascript #vuejs #web development

Writing multiple Vue components in a single file

Writing multiple components in one file is a pattern from React where some files contain multiple components. Some of those components are “private” to the file/exported component since no other component needs to consume them. ...

  • Hugo Di Francesco
    Author
4 min read
#node #jest #testing #javascript #Sequelize

Mocking/stubbing ES6 classes in tests with examples of Sequelize model unit tests

This post goes through some patterns that can be used to unit test ES6 classes. The examples will use Jest module auto-mocking but should be portable to other module mocking libraries (eg. Proxyquire) with some modifications. In “Using ES6 classes for Sequelize 4 models&rdq ...

  • Hugo Di Francesco
    Author
2 min read
#node #javascript #es6

Why you should wrap your (JavaScript) dependencies

An email sending example. ...

  • Hugo Di Francesco
    Author
2 min read
#graphql #tooling #web development

A gentle introduction to GraphQL API integrations

GraphQL is a great alternative to REST (or other HTTP API designs). This is an quick introduction to the core concepts around consuming a GraphQL API. To see some examples consuming a GraphQL API: In Python, see Python GraphQL client requests example using gql In JavaScript (brow ...

  • Hugo Di Francesco
    Author
5 min read
#javascript #node #graphql #web development

JavaScript GraphQL client requests in Node and the browser using `graphql.js`

An example consuming a GraphQL API in JavaScript from Node and the browser using graphql.js See the example live: https://example.codewithhugo.com/js-graphql-client-example/. Full repo: https://github.com/HugoDF/js-graphql-client-example. ...

  • Hugo Di Francesco
    Author
3 min read
#node #deployment #javascript #tooling

Build and deploy a Vue/React/Vanilla JS app with Parcel and GitHub pages

Parcel allows us to bundle frontend applications with no configuration and GitHub pages affords us a way to deploy them for free. Here’s how to use these two tools together to deploy a JavaScript application. Full example of a repo deployed like this: https://github.com/Hug ...

  • Hugo Di Francesco
    Author
2 min read
← Next Posts Page 11 of 14  Previous Posts →

Interested in Alpine.js?

Power up your debugging with the Alpine.js Devtools Extension for Chrome and Firefox. Trusted by over 15,000 developers (rated 4.5 ⭐️).

Install Now close
Code with Hugo
Latest Posts Github