Skip to content

Commit 178f467

Browse files
author
marker dao ®
committed
feat(bundle): Add imports
1 parent 8125345 commit 178f467

File tree

2 files changed

+23
-21
lines changed

2 files changed

+23
-21
lines changed

packages/devextreme/build/gulp/npm.js

+19-19
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const resultPath = ctx.RESULT_NPM_PATH;
2323

2424
const srcGlobsPattern = (path, exclude) => [
2525
`${path}/**/*.js`,
26-
// `!${path}/ai/**/*`,
26+
`!${path}/ai/**/*`,
2727
`!${exclude}/**/*.*`,
2828
`!${path}/bundles/*.js`,
2929
`!${path}/cjs/bundles/**/*`,
@@ -33,10 +33,10 @@ const srcGlobsPattern = (path, exclude) => [
3333
`!${path}/viz/docs/*.js`
3434
];
3535

36-
// const aiSrcGlobsPattern = (path, exclude) => [
37-
// `${path}/ai/*.js`,
38-
// `!${exclude}/**/*.*`,
39-
// ];
36+
const aiSrcGlobsPattern = (path, exclude) => [
37+
`${path}/ai/**/*`,
38+
`!${exclude}/**/*.*`,
39+
];
4040

4141
const esmPackageJsonGlobs = [
4242
`${ctx.TRANSPILED_PROD_ESM_PATH}/**/*.json`,
@@ -48,10 +48,10 @@ const esmSrcGlobs = srcGlobsPattern(
4848
ctx.TRANSPILED_PROD_RENOVATION_PATH
4949
);
5050

51-
// const aiEsmSrcGlobs = aiSrcGlobsPattern(
52-
// ctx.TRANSPILED_PROD_ESM_PATH,
53-
// ctx.TRANSPILED_PROD_RENOVATION_PATH,
54-
// );
51+
const aiEsmSrcGlobs = aiSrcGlobsPattern(
52+
ctx.TRANSPILED_PROD_ESM_PATH,
53+
ctx.TRANSPILED_PROD_RENOVATION_PATH,
54+
);
5555

5656
const distGlobsPattern = (jsFolder, exclude) => [
5757
'artifacts/**/*.*',
@@ -101,21 +101,21 @@ const licenseValidator = env.BUILD_INTERNAL_PACKAGE || env.BUILD_TEST_INTERNAL_P
101101
lazyPipe()
102102
.pipe(() => gulpFilter(['**', '!**/license/license_validation_internal.js']));
103103

104-
// const sources = (src, dist, distGlob, aiSrc) => (() => merge(
105-
const sources = (src, dist, distGlob) => (() => merge(
104+
const sources = (src, dist, distGlob, aiSrc) => (() => merge(
105+
// const sources = (src, dist, distGlob) => (() => merge(
106106
gulp
107107
.src(src)
108108
.pipe(licenseValidator())
109109
.pipe(headerPipes.starLicense())
110110
.pipe(compressionPipes.beautify())
111111
.pipe(gulp.dest(dist)),
112112

113-
// gulp
114-
// .src(aiSrc)
115-
// .pipe(licenseValidator())
116-
// .pipe(headerPipes.starLicense())
117-
// .pipe(compressionPipes.beautify())
118-
// .pipe(gulp.dest(dist)),
113+
gulp
114+
.src(aiSrc)
115+
.pipe(licenseValidator())
116+
.pipe(headerPipes.starLicense())
117+
.pipe(compressionPipes.beautify())
118+
.pipe(gulp.dest(dist)),
119119

120120
gulp
121121
.src(esmPackageJsonGlobs)
@@ -175,8 +175,8 @@ gulp.task('npm-sources', gulp.series(
175175
.src(`${resultPath}/${devextremeDistDir}/package.json`)
176176
.pipe(overwriteInternalPackageName())
177177
.pipe(gulpIf(env.BUILD_INTERNAL_PACKAGE, gulp.dest(distPath))),
178-
// sources(srcGlobs, packagePath, distGlobs, aiEsmSrcGlobs))
179-
sources(srcGlobs, packagePath, distGlobs))
178+
sources(srcGlobs, packagePath, distGlobs, aiEsmSrcGlobs))
179+
// sources(srcGlobs, packagePath, distGlobs))
180180
);
181181

182182
gulp.task('npm-dist', () => gulp
+4-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1-
// 1. Add all imports here
1+
/* global DevExpress */
2+
/* eslint-disable import/no-commonjs */
3+
import { AI } from '../ai/ai';
24

3-
import './modules/parts/widgets-web';
5+
module.exports = DevExpress.ai = AI;

0 commit comments

Comments
 (0)