我試圖安裝使用NPM和使用一飲而盡本教程語義的UI中找到semantic.json。 後來我直接到semantic/
文件夾,運行gulp build
而是說:一飲而盡無法語義的UI安裝
cannot find semantic.json. Run "gulp install" to set-up Semantic
的semantic.json
文件是在我的項目的根目錄。我也試過gulp install
但它說Task 'install' is not in your gulpfile
我該怎麼辦?
編輯: 這是我的gulpfile.js文件:
/*******************************
Set-up
*******************************/
var
gulp = require('gulp-help')(require('gulp')),
// read user config to know what task to load
config = require('./tasks/config/user'),
// watch changes
watch = require('./tasks/watch'),
// build all files
build = require('./tasks/build'),
buildJS = require('./tasks/build/javascript'),
buildCSS = require('./tasks/build/css'),
buildAssets = require('./tasks/build/assets'),
// utility
clean = require('./tasks/clean'),
version = require('./tasks/version'),
// docs tasks
serveDocs = require('./tasks/docs/serve'),
buildDocs = require('./tasks/docs/build'),
// rtl
buildRTL = require('./tasks/rtl/build'),
watchRTL = require('./tasks/rtl/watch')
;
/*******************************
Tasks
*******************************/
gulp.task('default', false, [
'watch'
]);
gulp.task('watch', 'Watch for site/theme changes', watch);
gulp.task('build', 'Builds all files from source', build);
gulp.task('build-javascript', 'Builds all javascript from source', buildJS);
gulp.task('build-css', 'Builds all css from source', buildCSS);
gulp.task('build-assets', 'Copies all assets from source', buildAssets);
gulp.task('clean', 'Clean dist folder', clean);
gulp.task('version', 'Displays current version of Semantic', version);
/*--------------
Docs
---------------*/
/*
Lets you serve files to a local documentation instance
https://github.com/Semantic-Org/Semantic-UI-Docs/
*/
gulp.task('serve-docs', 'Serve file changes to SUI Docs', serveDocs);
gulp.task('build-docs', 'Build all files and add to SUI Docs', buildDocs);
/*--------------
RTL
---------------*/
if(config.rtl) {
gulp.task('watch-rtl', 'Build all files as RTL', watchRTL);
gulp.task('build-rtl', 'Watch files as RTL ', buildRTL);
}
你想做什麼?你是否從'npm_modules/semantic'運行'gulp build'? 也添加你的'gulpfile.js',所以我們可以協助 –
我試圖安裝和使用semantic-ui在一個項目中。我正在'myproject/semantic'上運行'gulp build' – Navid777
您是否試圖將'semantic-ui'添加到您現有的項目中? –