2
0
mirror of https://github.com/tenrok/axios.git synced 2026-05-15 11:59:42 +03:00
Files
axios/bin/githubAxios.js
T
2023-11-08 20:14:12 +02:00

12 lines
284 B
JavaScript

import axios from '../index.js';
const {GITHUB_TOKEN} = process.env;
GITHUB_TOKEN ? console.log(`[GITHUB_TOKEN OK]`) : console.warn(`[GITHUB_TOKEN is not defined]`);
export default axios.create({
headers: {
Authorization: GITHUB_TOKEN ? `token ${GITHUB_TOKEN}` : null
}
})