コード例 #1
0
ファイル: DefPopup.js プロジェクト: aslafy-z/sourcegraph
	reconcileState(state, props) {
		Object.assign(state, props);
		state.defObj = props.def;
		state.repo = props.def ? props.def.Repo : null;
		state.rev = props.rev || null;
		state.commitID = props.def ? props.def.CommitID : null;
		state.def = props.def ? defPath(props.def) : null;

		state.authors = DefStore.authors.get(state.repo, state.commitID, state.def);
	}
コード例 #2
0
ファイル: routes.js プロジェクト: aslafy-z/sourcegraph
function defParams(def: Def, rev?: ?string): Object {
	const revPart = rev ? `@${rev}` : "";
	return {splat: [`${def.Repo}${revPart}`, defPath(def)]};
}