GithubHelp home page GithubHelp logo

jrlarsen / react-hooks-in-action Goto Github PK

View Code? Open in Web Editor NEW
166.0 6.0 131.0 9.87 MB

Code for the book React Hooks in Action

Home Page: http://www.room51.co.uk/books/reacthooks/index.html

HTML 38.01% CSS 20.54% JavaScript 41.45%

react-hooks-in-action's Introduction

React Hooks in Action

react-hooks-in-action's People

Contributors

dependabot[bot] avatar jrlarsen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

react-hooks-in-action's Issues

How do I handle npm install errors for experimental

Sorry, I have often struggled with npm install conflicts. Here is what I found:

git checkout 1305-multi-suspense
Branch '1305-multi-suspense' set up to track remote branch '1305-multi-suspense' from 'origin'.
Switched to a new branch '1305-multi-suspense'
rob@DESKTOP-0APTBSM:~/dv/node/react-hooks-in-action$ npm i
npm WARN old lockfile
npm WARN old lockfile The package-lock.json file was created with an old version of npm,
npm WARN old lockfile so supplemental metadata must be fetched from the registry.
npm WARN old lockfile
npm WARN old lockfile This is a one-time fix-up, please be patient...
npm WARN old lockfile
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR! react@"^0.0.0-experimental-3310209d0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.8.0 || ^17.0.0" from [email protected]
npm ERR! node_modules/react-query
npm ERR! react-query@"^3.5.11" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /home/rob/.npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/rob/.npm/_logs/2021-07-30T23_06_30_680Z-debug.log

I will experiment with --force and --legacy-peer-deps and npm-check-updates. I wonder when the features will no longer become experimental. I would like to see as much of the full booking example as possible and so I can browse the code in my IDE. Thanks so much. I love the new book!

import {bookables} doesn't work

This import statement

import {bookables} from "../../static.json";

Kept throwing an error when using filter with bookables. The following worked though..

const json = require('../../static.json');
export default function BookableList() {
const bookablesInGroup = json.bookables.filter(b => b.group === group);

cors error

Hi John
Do you have any idea on how I can fix cors request. I've tried many thing that I found on stackoverflow but nothing works
error

branch 0204 set index doesn't seem to work

When I use branch 2040-set-index I get the following error:

ERROR in ./src/components/Bookables/BookablesList.js 13:27-43
export 'bookables'.'filter' (imported as 'bookables') was not found in '../../static.json' (possible exports: 0, 1, 2, 3, 4, 5)
@ ./src/components/Bookables/BookablesPage.js 4:0-44 9:35-48
@ ./src/components/App.js 7:0-54 124:40-53
@ ./src/index.js 5:0-38 7:38-41

ERROR in ./src/components/Bookables/BookablesList.js 15:14-23
Should not import the named export 'bookables' (imported as 'bookables') from default-exporting module (only default export is available soon)
@ ./src/components/Bookables/BookablesPage.js 4:0-44 9:35-48
@ ./src/components/App.js 7:0-54 124:40-53
@ ./src/index.js 5:0-38 7:38-41

webpack 5.66.0 compiled with 2 errors in 102 ms

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.