L
L
LB7772015-04-21 13:39:18
gulp.js
LB777, 2015-04-21 13:39:18

How to include a configuration file in gulp to build a project?

How can I make gulp take data from my configuration file (it's in .json format) and substitute it into certain variables or constants of my project when building?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
Konstantin Kitmanov, 2015-04-21
@LB777

Please remove the npm tag from the question, it has nothing to do with it.
In general, require('./config.json') allows you to read the contents of the json file, and then everything is according to the official guide .
Found in 5 minutes, never used gulp.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question