Browse Source

refactor version import

pull/4855/head
afc163 8 years ago
parent
commit
aaa939cf87
  1. 4
      components/version/index.tsx
  2. 1
      typings/custom-typings.d.ts

4
components/version/index.tsx

@ -1,3 +1,3 @@
import * as pkg from '../../package.json'; import { version } from '../../package.json';
export default (pkg as any).version; export default version;

1
typings/custom-typings.d.ts

@ -86,5 +86,6 @@ declare var process: {
declare module "*.json" { declare module "*.json" {
const value: any; const value: any;
export const version: string;
export default value; export default value;
} }

Loading…
Cancel
Save