getFonts
is a Node.js project that demonstrates how to fetch fonts using the Express framework and the Axios library. It provides a basic server that serves font files in response to specific routes.
To install and run the getFonts
project, follow these steps:
-
Clone the repository:
git clone https://github.com/philipvella/getFonts.git
-
Change into the project directory:
cd getFonts
-
Install the dependencies:
npm install
To start the server and fetch fonts, use the following command:
npm start
The server will start and listen on the default port (3000).
The getFonts
project uses the following configuration file:
package.json
{
"name": "getFonts",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"start": "node server.js"
},
"author": "info@vellaphilip.com",
"license": "ISC",
"dependencies": {
"axios": "^1.4.0",
"express": "^4.18.2"
}
}
The following routes are available in the getFonts
project:
- GET /load-font: Fetches and serves the font file.
The getFonts
project relies on the following dependencies:
- Express: Fast, unopinionated, minimalist web framework for Node.js.
- Axios: Promise-based HTTP client for the browser and Node.js.
This project is licensed under the ISC License. See the LICENSE file for more information.