Socket
Socket
Sign inDemoInstall

craco-plugin-react-hot-reload

Package Overview
Dependencies
0
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    craco-plugin-react-hot-reload

This craco plugin, allows you to add hot load support to create-react-app without ejecting it


Version published
Weekly downloads
720
decreased by-21.31%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

craco-plugin-react-hot-reload

Prerequisites

Install craco and react-hot-reload

Install

npm install craco-plugin-react-hot-reload --save-dev

Usage

  1. Add the plugin into your craco.config.js;
reactHotReloadPlugin = require('craco-plugin-react-hot-reload');

module.exports = {
    plugins: [{
        plugin: reactHotReloadPlugin
    }]
}
  1. Follow 'step 2' from https://github.com/gaearon/react-hot-loader , replicated below:
Mark your root component as hot-exported:
// App.js
import React from 'react'
import { hot } from 'react-hot-loader'

const App = () => <div>Hello World!</div>

export default hot(module)(App)

Acknowledgements

@cdharris for having created react-app-rewire-hot-loader.

License

Licensed under the MIT License, Copyright ©️ 2017 Chris Harris. See LICENSE.md for more information.

Keywords

FAQs

Last updated on 15 Nov 2018

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc