其他分享
首页 > 其他分享> > [React] Build a feature toggle devtool

[React] Build a feature toggle devtool

作者:互联网

If you find yourself filling out the same form over and over again, or working through a weird workflow to enable certain features in your app just to get things developed, then custom DevTools for your app will enhance your productivity. There are so many things you can do once you are enabled to write arbitrary development-only code in your app. In this lesson we'll see how we can wire that up to make it possible.

 

in App.js, there is a feature toggle to switch the logo:

import React from 'react'
import featureToggles from './feature-toggles'
import logo from './logo.svg'
import './App.css'

function App() {
  return (
    <div className="App">
      <header className="App-header">
        {featureToggles.tacos ? (
          <span className="App-logo" role="img" aria-label="taco">
            

标签:load,featureToggles,devtool,dev,js,React,toggle,import,tools
来源: https://www.cnblogs.com/Answer1215/p/14193751.html