Skip to content

Instantly share code, notes, and snippets.

@unk
unk / list.jsx
Created September 22, 2019 09:23
const list = [
<UpdateList key={ '0' }/>,
<UpdateList key={ '1' }/>,
<UpdateList key={ '2' }/>,
]
ReactDOM.render( list, document.getElementById( '..' ) );
let userAgent = 'Mozilla/5.0 (iPhone; CPU iPhone OS 12_0 like Mac OS X) AppleWebKit/ 604.1.21 (KHTML, like Gecko) Version/ 12.0 Mobile/17A6278a Safari/602.1.26';
if (Platform.OS !== 'ios') {
userAgent = 'Mozilla/5.0 (Linux; Android 8.0.0; TA-1053 Build/OPR1.170623.026) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3368.0 Mobile Safari/537.36';
}
return (
<SafeAreaView>
<WebView
...
userAgent={userAgent}
...
@unk
unk / setState.js
Created March 6, 2019 07:57
setState.js
this.setState({value: 'changed!'}, () => console.log(this.state) );
@unk
unk / NoSPA.js
Created November 29, 2018 10:19
class CustomDocument extends Document {
render() {
return (
<html>
<Head>
</Head>
<body>
<nav className="navbar navbar-expand navbar-light bg-light">
...
@unk
unk / View.js
Last active November 29, 2018 09:04
import store from './store';
@observer
class View extends Component {
render() {
return <div>{ store.userName }</div>
}
}
export default View;
@unk
unk / Store.js
Last active November 29, 2018 09:03
class Store {
@observer userName = '';
}
export default new Store();
@unk
unk / .babelrc
Created November 29, 2018 09:01
{
"presets": [ "@babel/react" ],
"plugins": [
["@babel/plugin-proposal-decorators", {"legacy": true}],
["@babel/plugin-proposal-class-properties", {"loose": true}]
]
}
-- 암호 검증에 대한 플러그인을 제거합니다.
uninstall plugin validate_password;
-- 설정 업데이트
ALTER USER 'root'@'localhost'
IDENTIFIED WITH mysql_native_password
BY ''; -- homebrew로 설치시 기본 비밀번호는 '' 입니다. 본인의 설정에 맞게 변경하세요.
mysql -u root
default-authentication-plugin=mysql_native_password