forked from diplodoc-platform/cli
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconstants.ts
46 lines (40 loc) · 1.16 KB
/
constants.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import {plugins} from '@doc-tools/transform';
import {dirname} from 'path';
export const BUILD_FOLDER = 'build';
export const BUNDLE_FOLDER = '_bundle';
export const BUNDLE_FILENAME = 'app.js';
export const TMP_INPUT_FOLDER = '.tmp_input';
export const TMP_OUTPUT_FOLDER = '.tmp_output';
export const MAIN_TIMER_ID = 'Build time';
export const SINGLE_PAGE_FOLDER = '_single_page';
export enum Stage {
NEW = 'new',
PREVIEW = 'preview',
TECH_PREVIEW = 'tech-preview',
SKIP = 'skip',
}
export enum Lang {
RU = 'ru',
EN = 'en',
}
export const BUILD_FOLDER_PATH = dirname(process.mainModule?.filename || '');
const {notes, attrs, anchors, code, cut, deflist, includes, imsize, meta, sup, tabs, links, images, video} = plugins;
export const YFM_PLUGINS = [
attrs,
meta,
deflist,
includes,
cut,
links,
images,
notes,
anchors,
tabs,
code,
imsize,
sup,
video,
];
export const PROCESSING_HAS_BEEN_FINISHED = 'Processing file has been finished. File path';
export const getMsgСonfigurationMustBeProvided =
(repo: string) => `Сonfiguration must be provided for ${repo} like env variable or in .yfm file`;