Conversation
Style can be provided in request or as argument when starting Server
|
@buma Thank you for contributing this! Can you please add an example usage in comments here, or to the README? I want to make sure I understand the flow you have in mind from a usage perspective. |
brendan-ward
left a comment
There was a problem hiding this comment.
@buma a few minor tweaks to make, plus we need a bit more information about usage - a working example or two would be particularly helpful.
src/server.js
Outdated
| } else if (typeof default_styles === 'string') { | ||
| try { | ||
| // read styleJSON | ||
| const data = fs.readFileSync(default_styles, "utf8") |
There was a problem hiding this comment.
Is this correct? Your usage below for the command line interface suggests a directory of default style files, whereas here we are treating it as a path to a specific style JSON file.
There was a problem hiding this comment.
I updated usage now. Path to specific style JSON is needed.
|
Usage case is to specify style when you start the server and you don't need to sent it on each request. |
Style can be provided in request as a string or as argument when starting server.