Example function always return empty array
lucantini opened this issue · 3 comments
The example usage always return an empty array for me. Am I supposed to do something different? All of my Components are documented with styleguidist and my local server is running at 6060, just like the example. I then run the script and the examples
is always an empty Array.
While styleguidist is running locally I run:
const fs = require('fs');
const scrape = require('styleguidist-scrapper');
scrape('http://localhost:6060').then(examples => {
fs.writeFile('./examples-metadata.json', JSON.stringify(examples), 'utf8')
});
Same for me? any answers to this?
Could u share a repository with the issue reproduced? Would allow us fixing this much quicker.
I've created a simple repo with a single Button
Component that I've documented with styleguidist.
To reproduce the behavior run yarn docs
to run the styleguidist dev server and then run yarn scrape
, on another tab, to execute the script described above and in the documentation.
The example-metadata.json should be filled with the Button Component information, but it comes out as an empty array. Am I missing something here?