Skip to content

Instantly share code, notes, and snippets.

'use strict';
function createAdderJob(val) {
return function adder(g) {
g.entry = g.entry.map(src => src + val);
return g;
}
}
module.exports = createAdderJob;
'use strict';
import React from 'react';
class BaseComponent extends React.Component {
componentDidMount() {
// ref error will be given,
// this.refs.root === <div>
// this.refs.subrender === null
console.log(this.refs);
function hello(callback) {
callback('World')
}
hello(function(str) {
console.log('Hello', str);
})
@kjessec
kjessec / Q_App.js
Last active February 8, 2019 04:03
React 1일차 코드 잘 모르는 부분
import React, { Component } from 'react';
import logo from './logo.svg';
import './App.css';
const data = [
{ title: 'Hello World', content: 'Hello 1234', writer: 'JESSE'},
{ title: 'Hello World1', content: 'Hello 1asdf234'},
{ title: 'Hello World2', content: 'Helasdflo 1234'},
{ title: 'Hello World3', content: 'Heladsflo 1234'},
{ title: 'Hello World4', content: 'Helasdblo 1234'},