2018-05-18 17:59:23 +00:00
|
|
|
/* @flow */
|
|
|
|
|
|
|
|
import path from 'path';
|
|
|
|
|
|
|
|
export const ABSOLUTE_BASE: string = path.normalize(path.join(__dirname, '..'));
|
|
|
|
|
|
|
|
const constants: Object = Object.freeze({
|
|
|
|
BUILD: path.join(ABSOLUTE_BASE, 'build/'),
|
2018-09-04 15:10:52 +00:00
|
|
|
PUBLIC: path.join(ABSOLUTE_BASE, 'public/'),
|
2018-05-18 17:59:23 +00:00
|
|
|
SRC: path.join(ABSOLUTE_BASE, 'src/'),
|
2019-02-13 21:51:25 +00:00
|
|
|
TRANSLATIONS: path.join(ABSOLUTE_BASE, 'public/l10n'),
|
2018-05-18 17:59:23 +00:00
|
|
|
PORT: 8081,
|
|
|
|
INDEX: path.join(ABSOLUTE_BASE, 'src/index.html'),
|
2018-08-08 09:41:08 +00:00
|
|
|
TREZOR_CONNECT_ROOT: path.join(ABSOLUTE_BASE, '../trezor-connect/'),
|
2018-05-18 17:59:23 +00:00
|
|
|
});
|
|
|
|
|
2018-09-06 15:04:28 +00:00
|
|
|
export const { TREZOR_CONNECT_ROOT }: { TREZOR_CONNECT_ROOT: string } = constants;
|
2018-08-08 09:41:08 +00:00
|
|
|
export const TREZOR_CONNECT: string = path.join(constants.TREZOR_CONNECT_ROOT, 'src/js/index');
|
2019-03-04 12:33:02 +00:00
|
|
|
export const TREZOR_IFRAME: string = path.join(
|
|
|
|
constants.TREZOR_CONNECT_ROOT,
|
|
|
|
'src/js/iframe/iframe.js'
|
|
|
|
);
|
|
|
|
export const TREZOR_POPUP: string = path.join(
|
|
|
|
constants.TREZOR_CONNECT_ROOT,
|
|
|
|
'src/js/popup/popup.js'
|
|
|
|
);
|
|
|
|
export const TREZOR_WEBUSB: string = path.join(
|
|
|
|
constants.TREZOR_CONNECT_ROOT,
|
|
|
|
'src/js/webusb/index.js'
|
|
|
|
);
|
2018-08-08 09:41:08 +00:00
|
|
|
export const TREZOR_CONNECT_HTML: string = path.join(constants.TREZOR_CONNECT_ROOT, 'src/html/');
|
|
|
|
export const TREZOR_CONNECT_FILES: string = path.join(constants.TREZOR_CONNECT_ROOT, 'src/data/');
|
|
|
|
|
2018-09-06 15:04:28 +00:00
|
|
|
export const {
|
|
|
|
BUILD,
|
|
|
|
SRC,
|
2019-02-06 17:01:09 +00:00
|
|
|
TRANSLATIONS,
|
2018-09-06 15:04:28 +00:00
|
|
|
PORT,
|
|
|
|
INDEX,
|
|
|
|
PUBLIC,
|
2019-03-04 12:33:02 +00:00
|
|
|
}: {
|
|
|
|
BUILD: string,
|
|
|
|
SRC: string,
|
|
|
|
TRANSLATIONS: string,
|
|
|
|
PORT: string,
|
|
|
|
INDEX: string,
|
|
|
|
PUBLIC: string,
|
|
|
|
} = constants;
|
2018-09-06 15:04:28 +00:00
|
|
|
// export const SRC: string = constants.SRC;
|
|
|
|
// export const PORT: string = constants.PORT;
|
|
|
|
// export const INDEX: string = constants.INDEX;
|
|
|
|
// export const PUBLIC: string = constants.PUBLIC;
|
2018-05-18 17:59:23 +00:00
|
|
|
|
2019-03-04 12:33:02 +00:00
|
|
|
export default constants;
|