Giter Site home page Giter Site logo

esdoc-node's People

Contributors

eliasthompson avatar gb-ihealth avatar homer0 avatar islavinskyi avatar lcodes avatar

Stargazers

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

Watchers

 avatar  avatar

esdoc-node's Issues

Error with method call on require

Calling a method directly on the require doesn't work.
Here's an example:

require('dotenv').config();

When running esdoc with this plugin it logs the following error:

warning: could not parse the following code. if you want to use ECMAScript proposals, see https://esdoc.org/manual/feature.html#ecmascript-proposal
/Users/egon/src/dolphin/test.js
1| require('dotenv').config();
2|

Version 1.0.5 has a bug for destructuring

@lcodes This is what I already commented on #7. The PR removed one of the basic functionalities of the plugin (and even the tests for it) in order to add support for very edge case:

const { one: { two } } = required('...');

In order to add support for that, the support for this was removed:

const { one } = require('...');

I believe one level destructuring should be enough, as it's "basically the same" as a named import on ES, while destructuring on multiple levels doesn't exist.

From what I understand, this plugin was made in order to transpile to the syntax ESDoc uses, ESModules, not just to get coverage when you use require.

Also, have in mind that you released it as a fix and this was super breaking; I have ~15 public projects, using this plugin, that lost their coverage because of the hidden variable added on the PR.

Please, revert #7

module.exports = { ... } does not seem to generate any docs

Code of the following form does not seem to generate any docs. The source file is present on the source.html page, but none of the a, b, c, identifiers are associated with the source file (on the source.html page), and no function reference appears in the left-hand menu.

function a() {}
function b() {}
function c() {}

module.exports = {
  a,
  b,
  c,
};

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.