网友回复
打开网址:https://github.com/settings/tokens
点击生成新的token


输入名字,选择不过期,然后勾选repo


复制token,新建一个repo,例如bfw/test

<!DOCTYPE html>
<html>
<head>
<title>GitHub API File Upload</title>
</head>
<body>
<input type="file" id="fileInput" />
<button id="uploadButton">Upload</button>
<script>
document.getElementById('uploadButton').addEventListener('click', async () => {
const token = '';//换成你自己的
const repo = 'bfw/test';//换成你自己的
const fileInput = document.getElementById('fileInput');
const file = fileInput.files[0];
if (!file) {
ale...点击查看剩余70%


