All Projects → preactjs → preact-integrations

preactjs / preact-integrations

Licence: MIT License
A collection of sample apps demonstrating Preact's compatibility with various 3rd party libraries

Programming Languages

javascript
184084 projects - #8 most used programming language
SCSS
7915 projects
CSS
56736 projects
EJS
674 projects

Projects that are alternatives of or similar to preact-integrations

preact-polka-ssr
Preact SSR using Polka
Stars: ✭ 27 (-18.18%)
Mutual labels:  preact, preact-demos
preact-motion
A fork of React-Motion to be used with Preact
Stars: ✭ 28 (-15.15%)
Mutual labels:  preact, preact-demos
preact-compat-example
🚤 Demo of preact-compat + react-toolbox to reduce build size by 95%.
Stars: ✭ 52 (+57.58%)
Mutual labels:  preact, preact-demos
react-native-react-bridge
An easy way to integrate your React (or Preact) app into React Native app with WebView.
Stars: ✭ 84 (+154.55%)
Mutual labels:  preact
weather-sucks
Weather App with Estonian Mood
Stars: ✭ 23 (-30.3%)
Mutual labels:  preact
apps
daily.dev application suite
Stars: ✭ 253 (+666.67%)
Mutual labels:  preact
proptypes
💂‍♂️ React's PropTypes, as a standalone module.
Stars: ✭ 60 (+81.82%)
Mutual labels:  preact
spoken-word
Spoken Word
Stars: ✭ 46 (+39.39%)
Mutual labels:  preact
preact-component-console
A console emulator for preact.
Stars: ✭ 29 (-12.12%)
Mutual labels:  preact
desvg
🌅 Converts SVG files into components 🌞
Stars: ✭ 79 (+139.39%)
Mutual labels:  preact
scala-js-preact
Scala.js facade for the Preact JavaScript library
Stars: ✭ 25 (-24.24%)
Mutual labels:  preact
preact-views
📺 Named views for Preact, with easy-as-pie linking between them.
Stars: ✭ 39 (+18.18%)
Mutual labels:  preact
fly-kit-preact
A starter kit for building offline / SPA / PWA apps with Preact
Stars: ✭ 28 (-15.15%)
Mutual labels:  preact
preact-server-renderer
Server side rendering of preact components
Stars: ✭ 66 (+100%)
Mutual labels:  preact
dl-model
Dragalia Lost Model Viewer
Stars: ✭ 30 (-9.09%)
Mutual labels:  preact
preact-delegate
Preact delegate DOM events
Stars: ✭ 17 (-48.48%)
Mutual labels:  preact
csgo-rcon-nodejs
A web panel to control a CS:GO server
Stars: ✭ 46 (+39.39%)
Mutual labels:  preact
stoxy
Stoxy is a state management API for all modern Web Technologies
Stars: ✭ 73 (+121.21%)
Mutual labels:  preact
jasonformat.com
My blog
Stars: ✭ 18 (-45.45%)
Mutual labels:  preact
preact-perf-profiler
A HOC to enable measuring rendering performance for Preact components
Stars: ✭ 18 (-45.45%)
Mutual labels:  preact

Preact Integrations

A collection of sample apps demonstrating Preact's compatibility with various 3rd party libraries


Description

This repo contains a collection of simple Preact apps that demonstrate how to use preact with various 3rd party libraries including react-redux, mobx-react, react-router, and more!

The apps are divided into 2 categories: direct and full-compat. Libraries in the "src/direct" directory can be used with preact directly and don't require preact/compat. Libraries in the "full-compat" directory require aliasing react to preact/compat.

We are looking for contributors to add more libraries to this repository! If that's you, read on to find out how to get started!


🤝 Contributing

There are many ways to help our project. Some include:

  • Request a library to add
  • Adding libraries
  • Adding tests for libraries
  • File issues for bugs in sample apps
  • Fixing bugs in sample apps

Check out our CONTRIBUTING guide for details on how to contribute.


🛠 Setup and building

Follow these steps to setup and run this project locally.

  1. Install NPM dependencies:

    npm install
  2. Run our dev script to build the project and start the development server:

    npm run dev

🏎 Development scripts

Our package.json comes with same basic scripts to help you get started working in our repo. When using npm to run our commands, be sure to add -- before passing in any options to make sure they reach our script and aren't consumed by npm.

dev

The dev script will watch the files in src and re-build our scripts when one of them changes. If you know what library you are working on and just want to watch those files, pass the name of the library to the dev script like so: npm run dev preact-router. This command will start the dev server and only watch the files necessary to re-build the script bundle that includes preact-router.

$ npm run dev -- --help

  Description
    Watch src files of the passed in libraries (defaults to all), build them on change, and run a web server to serve them

  Usage
    $ scripts dev [libraries] [options]

  Options
    -m, --mode    'production' or 'development'  (default development)
    --debug       Print out debugging info  (default false)
    --preact      Path to a preact repo or package to bundle instead of the node_modules version.
		              Must be a path to the directory containing the root package.json in the Preact repo	 or package.
    -h, --help    Displays this message

build

$ npm run build -- --help

  Description
    Build the bundles that include the libraries passed in (defaults to building all)

  Usage
    $ scripts build [libraries] [options]

  Options
    -m, --mode     'production' or 'development'  (default production)
    -w, --watch    Watch source files and rebuild on change  (default false)
    --debug        Print out debugging info  (default false)
    --preact       Path to a preact repo or package to bundle instead of the node_modules version.
		               Must be a path to the directory containing the root package.json in the Preact repo or package.
    -h, --help     Displays this message

test

The test command just runs jest so all Jest CLI options are supported. The most useful one is passing in a pattern to filter which tests are run. For example, if you only want to run the preact-router tests, just pass in the string preact-router to only run tests that match that pattern:

npm run test preact-router

test:debug

Launch jest and puppeteer with options to enable debugging the tests in Chromium. This will launch Chromium with headless turned off and devtools turned on. These options enable you to call jestPuppeteer.debug() in your test to pause jest and pause the browser. See the jest-puppeteer docs for more info.

Also see the "Debugging tests" section in the CONTRIBUTING guide.

serve

$ npm run serve -- --help

  Description
    Run a development web server

  Usage
    $ scripts serve [options]

  Options
    --debug       Print out debugging info  (default false)
    --preact      Path to a preact repo or package to bundle instead of the node_modules version.
		              Must be a path to the directory containing the root package.json in the Preact repo or package.
    -h, --help    Displays this message

👀 Code Reviews

All submissions, including submissions by project members, require review. It's a great way to learn. We use GitHub pull requests for this purpose. Consult GitHub Help for more information on using pull requests.


Using with Preact repo

If you are a contributor to the main Preact repo, you can point this repo to your local Preact repo to validate changes you make there. For any of the commands above, specify a --preact option to build the integrations website with your local repo. Point the --preact option to the top folder of the Preact repo that contains the root package.json.


🥂 License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].