Coder Social home page Coder Social logo

gulp-docco's People

Contributors

cyparu avatar dmp42 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gulp-docco's Issues

Error: Cannot find module 'through2'

I am getting this error when running the gulp docco. I have lifted the version of through2 locally, which worked.
Can you update the dependencies?

Error: Cannot find module 'through2'
  at Function.Module._resolveFilename (module.js:338:15)
  at Function.Module._load (module.js:280:25)
  at Module.require (module.js:364:17)
  at require (module.js:380:17)
  at /Users/rob/Repos/thestack/node_modules/gulp-docco/index.js:4:18
  at Object.<anonymous> (/Users/rob/Repos/thestack/node_modules/gulp-docco/index.js:122:2)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (/Users/rob/Repos/thestack/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
  at Function.Module._load (module.js:312:12)
  at Module.require (module.js:364:17)
  at require (module.js:380:17)
  at Object.<anonymous> (/Users/rob/Repos/thestack/Gulpfile.coffee:25:9)
  at Object.<anonymous> (/Users/rob/Repos/thestack/Gulpfile.coffee:1:1)
  at Module._compile (module.js:456:26)
  at Object.loadFile (/Users/rob/Repos/thestack/node_modules/coffee-script/lib/coffee-script/register.js:16:19)
  at Module.load (/Users/rob/Repos/thestack/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
  at Function.Module._load (module.js:312:12)
  at Module.require (module.js:364:17)
  at require (module.js:380:17)
  at Object.<anonymous> (/Users/rob/Repos/thestack/Gulpfile.js:4:1)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (module.js:356:32)
  at Function.Module._load (module.js:312:12)
  at Module.require (module.js:364:17)
  at require (module.js:380:17)
  at Liftoff.handleArguments (/usr/local/lib/node_modules/gulp/bin/gulp.js:116:3)
  at Liftoff.<anonymous> (/usr/local/lib/node_modules/gulp/node_modules/liftoff/index.js:159:12)
  at module.exports (/usr/local/lib/node_modules/gulp/node_modules/liftoff/node_modules/flagged-respawn/index.js:17:3)
  at Liftoff.launch (/usr/local/lib/node_modules/gulp/node_modules/liftoff/index.js:152:5)
  at Object.<anonymous> (/usr/local/lib/node_modules/gulp/bin/gulp.js:67:5)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (module.js:356:32)
  at Function.Module._load (module.js:312:12)
  at Function.Module.runMain (module.js:497:10)
  at startup (node.js:119:16)
  at node.js:906:3

Missing dependencies

My installation on Windows using npm required the following additional dependencies, all used from vinyl-fs:

  • map-stream
  • ordered-read-streams
  • unique-stream
  • minimatch
  • lodash._basecreatecallback
  • lodash._baseisequal
  • lodash._objecttypes
  • lodash._property
  • graceful-fs
  • mkdirp
  • glob-watcher

Passing template path to config errors

Below is my docco task:

gulp.task('docco', function() {
  gulp.src(['index.js'])
    .pipe(tasks.docco({
      css: 'docco-custom.css',
      template: 'docco-custom.jst'
    }))
    .pipe(gulp.dest('./'));
});

Without the template property, everything works as expected. But with the template specified, the gulp task errors:

/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/lib/backend.js:48
      var html = config.template({
                        ^
TypeError: Property 'template' of object #<Object> is not a function
    at process (/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/lib/backend.js:48:25)
    at Transform.<anonymous> (/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/index.js:70:14)
    at Transform.<anonymous> (/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/node_modules/through2/node_modules/readable-stream/lib/_stream_transform.js:130:12)
    at Transform.g (events.js:180:16)
    at Transform.EventEmitter.emit (events.js:92:17)
    at finishMaybe (/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/node_modules/through2/node_modules/readable-stream/lib/_stream_writable.js:363:12)
    at endWritable (/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/node_modules/through2/node_modules/readable-stream/lib/_stream_writable.js:370:3)
    at Transform.Writable.end (/Users/cmalven/Dropbox/Desktime/Desktime - Space Agreement/desktime-space-agreement/node_modules/gulp-docco/node_modules/through2/node_modules/readable-stream/lib/_stream_writable.js:348:5)
    at Stream.onend (stream.js:79:10)
    at Stream.EventEmitter.emit (events.js:117:20)

Both css and jst files are in the same directly as the gulp file, and the custom css works perfectly. Any ideas?

Does not "finish"

I have a task called "docs" that looks like this:

gulp.task('docs', function() {
  return gulp.src('src/*')
    .pipe(docco())
    .pipe(gulp.dest('docs'))
});

It never "finishes". It shows:

$ gulp docs
[23:26:51] Using gulpfile ~/test/gulpfile.js
[23:26:51] Starting 'docs'...
$

It SHOULD show:

$ gulp docs
[23:27:07] Using gulpfile ~/test/gulpfile.js
[23:27:07] Starting 'docs'...
[23:27:07] Finished 'docs' after 22 ms
$

I'm not sure if this is because it doesn't provide an appropriate stream or what. It breaks other tasks by never getting to them when serializing them with docs as a dependency.

Pathing to the generated css file doesn't work in subdirectories.

if the following gulp configuration is used:

    gulp.src("./src/**/*.coffee")
      .pipe(docco())
      .pipe(gulp.dest('./docs'));

The docco.css file is output to docs and the HTML files are output to a directory structure that is mirroring the src one. For example if a coffee file is in src/core/test.coffee the resulting HTML file would be in docs/core/test.html.

Inside that HTML file the CSS link to docco.css is assuming that a docco.css file exists in the current directory.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.