learn-co-curriculum / redux-dispatch-with-event-listeners Goto Github PK
View Code? Open in Web Editor NEWLicense: Other
License: Other
This exercise does not have a .learn file, which causes learn-open (1.2.28) to break when LearnOpen>Lesssons>IosLesson fails to find a :languages key there (/learn-open-1.2.28/lib/learn_open/lessons/ios_lesson.rb:6)
..."Here it is: you click on a button, and you see a number on the page go to zero to one."
Should be:
Here it is: you click on a button, and you see a number on the page go from zero to one.
function render(){
let container = document.getElementById('container');
container.textContent = state.count;
}
The above code snippet is from directly below 3. Using the render function to display our state
which conflicts with what is being shown later on in the readme in the last snippet of section 4 which includes
function render() {
document.setInnerHtml = state.count;
}
This lesson has a reference to it "having been a long time since you set up an event without jQuery" but our curriculum doesn't include jQuery. Old lesson?
Suggest putting the word "can" before "access" in this sentence:
"It access the state because it is declared earlier in the file in global scope."
Thank you.
As per lessons instructions:
"Now, if instead we want to show the number zero, our default state, well we can just refresh our page, and then dispatch an action that returns the default state like so: dispatch(type: '@@init'). "
Results in the following error:
SyntaxError: missing ) after argument list
Correct console command should be:
dispatch({type: '@@init'})
Why is the render method changed to:
function render(){
document.setInnerHtml = state.count
}
Shouldn't it stay as
function render(){
let container = document.getElementById('container');
container.textContent = state.count;
}
It's best practice, plus it avoids scoping errors in callbacks.
This makes following along this code-along near impossible.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.