Skip to content

Instantly share code, notes, and snippets.

@attom2
Last active June 26, 2020 19:59
Show Gist options
  • Select an option

  • Save attom2/2b82fbd4e21e9329781bf2ebf68daf18 to your computer and use it in GitHub Desktop.

Select an option

Save attom2/2b82fbd4e21e9329781bf2ebf68daf18 to your computer and use it in GitHub Desktop.

What is a "framework?" And how does it differ from a "library?"

A framework is a set of pre-written rules that allow a developer to perform certain tasks without writing all of the code. A library has less rules than a framework.

Why should we consider using a framework over vanilla JS like you have been doing in mods 1 and 2?

It allows us to write code more efficiently so we don't have to reinvent the wheel.

What is a "component" in React? Why is it useful to have components?

A component is a file that interacts with the dom in some way, it allows each file to be much smaller and more readable. It allows the UI to be updated with the current state.

What is JSX?

A special programming language designed to look and act somewhat like html but with a few differences.

What are React "props?"

Data that are passed into a component, similar to a function and argument in JS.

What is React "state?"

The state object is where you store property values that belongs to the component.

What does "data down, actions up" mean in React?

Components should not mutate the data, so we only want to perform actions not manipulate data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment