Loadable Components

The recommended Code Splitting library for React

README

loadable-components

React code splitting made easy. Reduce your bundle size without stress ✂️✨.

License npm package npm downloads Build Status
Code style Dependencies DevDependencies Small size

  1. ``` sh
  2. npm install @loadable/component
  3. ```


See the documentation at loadable-components.com for more information about using Loadable Components!

Quicklinks to some of the most-visited pages:

- [Getting started](https://loadable-components.com/docs/getting-started/)

Example


  1. ``` js
  2. import loadable from '@loadable/component'

  3. const OtherComponent = loadable(() => import('./OtherComponent'))

  4. function MyComponent() {
  5.   return (
  6.     <div>
  7.       <OtherComponent />
  8.     </div>
  9.   )
  10. }
  11. ```

Supporting Loadable Components


Loadable Components is an MIT-licensed open source project. It's an independent project with ongoing development made possible thanks to the support of these awesome backers. If you'd like to join them, please consider:


License


Licensed under the MIT License, Copyright © 2017-present Greg Bergé.

See LICENSE for more information.