Skip to content

Instantly share code, notes, and snippets.

Avatar

Matheus Lima matheusml

View GitHub Profile
View simple-tester.js
function describe(description, callback) {
console.log(description);
callback();
}
function it(description, callback) {
console.log(description);
callback();
}
View test.js
describe("booleans", () => {
it("false === false", () => {
expect(false).toBe(false);
});
it("true === true", () => {
expect(true).toBe(true);
});
});
View blockstack
Verifying my Blockstack ID is secured with the address 1BwQZHU6Hi4xA1KoYao83Swad5bbfeBtxd https://explorer.blockstack.org/address/1BwQZHU6Hi4xA1KoYao83Swad5bbfeBtxd
View ex.sh
$ yarn global add create-react-app
$ npm install -g create-react-app
$ create-react-app NOME_PROJETO
$ cd NOME_PROJETO
View ex.bash
yarn add create-react-app
View webpack.js
{
test: /\.css$/,
loader: 'style-loader!css-loader',
},
{
test: /\.scss$/,
loader: 'style!css-loader?modules&importLoaders=1&localIdentName=[name]__[local]___[hash:base64:5]',
}
View Main.js
import React from 'react';
import styles from './styles.css';
const Main = () => (
<button
onClick={() => alert('Clicked')}
className={styles.button}
>Click me</button>
);
View Main.js
import React from 'react';
const styles = {
backgroundColor: 'blue',
border: 'none',
color: white,
padding: '5px 10px'
};
const Main = () => (
View styles.css
.button {
background-color: blue;
border: none;
color: white;
padding: 5px 10px;
}
View styles.css
#button {
background-color: blue;
border: none;
color: white;
padding: 5px 10px;
}
You can’t perform that action at this time.