error TS2305: Module '"gulp"' has no exported member 'parallel'
duke-git opened this issue · comments
DuDaoDong commented
Before you open this issue, please complete the following tasks:
- use the search bar at the top of the page to search this repository for similar issues or discussions that have already been opened.
- if you are looking for help from the gulp team or community, open a discussion.
- if you think there is a problem with the plugin you're using, open a discussion.
- if you think there is a bug in our code, open this issue.
What were you expecting to happen?
in gulp file. the import series, and parallel should works.
What actually happened?
error: error TS2305: Module '"gulp"' has no exported member
Please give us a sample of your gulpfile
import delPath from '../utils/delpath'
import { series, parallel, src, dest } from 'gulp'
import { pkgPath, componentPath } from '../utils/paths'
import less from 'gulp-less'
import autoprefixer from 'gulp-autoprefixer'
import run from '../utils/run'
//删除kui
export const removeDist = () => {
return delPath(`${pkgPath}/kui`)
}
//打包样式
export const buildStyle = () => {
return src(`${componentPath}/src/**/style/**.less`)
.pipe(less())
.pipe(autoprefixer())
.pipe(dest(`${pkgPath}/kui/lib/src`))
.pipe(dest(`${pkgPath}/kui/es/src`))
}
//打包组件
export const buildComponent = async () => {
run('pnpm run build', componentPath)
}
export default series(
async () => removeDist(),
parallel(
async () => buildStyle(),
async () => buildComponent()
)
)
Terminal output / screenshots
$ gulp
Please provide the following information:
- OS & version [e.g. MacOS Catalina 12.6]:
- node version (run
node -v
): v16.16.0 - npm version (run
npm -v
): 8.11.0 - gulp version (run
gulp -v
): CLI version: 2.3.0 Local version: 4.0.2
Additional information
DuDaoDong commented
Blaine Bublitz commented
Duplicate of #2634