Lalit Mohan
Lalit Mohan

Reputation: 474

How to use font-awesome with node + express framework

Without less file is there any chance to use font-awesome in node with express framework Please help Thank You

Upvotes: 4

Views: 3344

Answers (1)

Bharathvaj Ganesan
Bharathvaj Ganesan

Reputation: 3194

Set the public directory and include the font-awesome library.

/* Public static directory */ app.use(express.static(__dirname + '/public'));

So your app structure should be something like this,

public/ vendor/ font-awesome-4.7.0/ css/ js/ ..etc

In your html file include as usual

<link rel="stylesheet" href="../vendor/font-awesome-4.7.0/css/font-awesome.min.css">

Upvotes: 2

Related Questions