Skip to content

Latest commit

 

History

History

examples

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Halogen Hook Examples

The examples in this directory demonstrate how to use hooks to build ordinary Halogen components, and also demonstrate a few examples of what you can do with hooks that you couldn't do with regular components.

View live examples

You can view and test the examples by bundling the project. Run these commands from the root of the repository:

# Ensure you have installed dependencies
npm install

# Bundle the examples to ./example/app.js
npm run bundle:examples

Open ./examples/index.html to view the live examples.

Contributing

I'd love to expand these examples in two ways:

  • Direct comparisons between Hooks-based and ordinary Halogen components
  • New custom hooks which showcase Hooks functionality

Please focus on comparisons and Hooks features that aren't already covered by the existing examples to help prevent these examples from becoming a maintenance burden.