Skip to content

Instantly share code, notes, and snippets.

Working from home

KenjiMorita kenmori

Working from home
View GitHub Profile
kenmori /
Created Jan 7, 2017
【glassFish】これが出たら疑う箇所Exception [EclipseLink-28019] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.EntityManagerSetupException
@SecondaryTable(name = "zipcode_tbl"),//not much!!
@SecondaryTable(name = "address_tbl"),
public class UserEntity02 implements Serializable {
@Id @NotNull
private String id;
private String name;
kenmori / persistence.xml
Created Jan 7, 2017
【JavaDB/glassFish】解決!Internal Exception: java.sql.SQLSyntaxErrorException: 表またはビュー'[TABLE_NAME]'は存在しません。
View persistence.xml
<!--add this code, if you use eclipselink -->
<property name="eclipselink.ddl-generation" value="create-tables"/>
kenmori /
Created Jan 8, 2017
【Rust/rustup/multirust】uninstallしたい!「rustup cannot be installed alongside [Rust|multirust]. Please uninstall first」rustcが邪魔してrustupがinstallできない場合1つの方法
sudo /usr/local/lib/rustlib/
kenmori /
Created Feb 5, 2017


イベントデリゲーションに関して。 こちらのDOMの

<ul id="todo-app">
  <li class="item">Walk the dog</li>
  <li class="item">Pay bills</li>
  <li class="item">Make dinner</li>
kenmori / Child-keys-must-be-unique.js
Last active Feb 10, 2017
keyを持つコードとkeyを持たないコード【React】これ。Warning: flattenChildren(...): Encountered two children with the same key, `keyName`. Child keys must be unique; when two children share a key, only the first child will be used.
View Child-keys-must-be-unique.js
////////no key////////keyを持たないで返しているコード///
const users = (user){
return <User id={} name={} />;
////////add key//////keyを設定して返しているコード///
const users = (user){
return <User id={} key={} name={} />;
kenmori / gist:6c3cb9d5d6a15205a9a54a15e7fad37e
Last active Feb 15, 2017
flowtype/react. Required module not found
View gist:6c3cb9d5d6a15205a9a54a15e7fad37e
import React, { Component } from 'hogehogefolder/react';//error react. Required module not found
const MailToBtn = ({mailAddress, addClass, children }: Props) => (
<a className='block w100 ' href={mailAddress}>
<button className={`${addClass} appearanceNone outlineNone btnMain btnShadow1 size1 type1 btn100 pad0`} type='button'>
export default MailToBtn
View .flowtype.config
[libs]//add flowtyed folder
kenmori / enterns.js
Created Feb 15, 2017
add flowtyped js file to folder after set libs in .flowtype.config 【flowtype】これ。react. Required module not found
View enterns.js
declare module 'hogehogefolder/react' {
declare module.exports: any;
kenmori / Required-module-not-found.txt
Created Feb 15, 2017
react. Required module not found
View Required-module-not-found.txt
3: import React, { Component } from 'tel_fortune_lib/react';
^^^^^^^^^^^^^^^^^^^^^^^ hogehogefolder/react. Required module not found
kenmori / flowtype.js
Created Feb 18, 2017
【flowtype/React/Class】これ。how to fix 「Covariant property `[fn]` incompatible with contravariant use in ``` assignment of property `[fn]`」
View flowtype.js
this._increment = this._increment.bind(this);
^^^^^^^^^^ property `_increment`. Covariant property `_increment` incompatible with contravariant use in
27: this._increment = this._increment.bind(this);
^^^^^^^^^^^^^^^ assignment of property `_increment`
/////// code ////////
constructor(props: Props){
this.state = {