lichess-org / api-demo Goto Github PK
View Code? Open in Web Editor NEWClient-side app using various Lichess APIs for demonstration purpose
Home Page: https://lichess-org.github.io/api-demo/
License: GNU Affero General Public License v3.0
Client-side app using various Lichess APIs for demonstration purpose
Home Page: https://lichess-org.github.io/api-demo/
License: GNU Affero General Public License v3.0
I just downloaded a fresh copy of this repo and ran the setup instructions. The server runs but the site that loads is always a blank page. Here are my console warnings (on Chrome, Mac OSX)
CLI output from build:
Starting up http-server, serving ./
http-server version: 14.1.0
http-server settings:
CORS: disabled
Cache: 3600 seconds
Connection Timeout: 120 seconds
Directory Listings: visible
AutoIndex: visible
Serve GZIP Files: false
Serve Brotli Files: false
Default File Extension: none
Available on:
http://127.0.0.1:8080
http://192.168.1.200:8080
Hit CTRL-C to stop the server
Upfront I will grant the possibility that I don't know what I'm doing… That said, here is what I did:
C:\Users\hsmyers>mkdir Lichess
C:\Users\hsmyers>cd Lichess
C:\Users\hsmyers\Lichess>npm install
npm WARN saveError ENOENT: no such file or directory, open 'C:\Users\hsmyers\Lichess\package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\hsmyers\Lichess\package.json'
npm WARN Lichess No description
npm WARN Lichess No repository field.
npm WARN Lichess No README data
npm WARN Lichess No license field.
up to date in 0.334s
found 0 vulnerabilities
Starting with the first warning, I deleted the lock file and copied the package.json file from this site to my machine and got this:
C:\Users\hsmyers\Lichess>npm install
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.3.2 (node_modules\rollup\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN [email protected] requires a peer of @popperjs/core@^2.11.6 but none is installed. You must install peer dependencies yourself.
added 133 packages from 166 contributors and audited 134 packages in 64.788s
22 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
I assumed I could survive the first two warnings (marked optional as they are) but had my doubts about the 'install peer dependencies remark. but to confirm, I went ahead and:
C:\Users\hsmyers\Lichess>npm run build
> lichess-oauth-app-example@ build C:\Users\hsmyers\Lichess
> rollup --config
[!] Error: Could not resolve entry module (rollup.config.js).
Error: Could not resolve entry module (rollup.config.js).
at error (C:\Users\hsmyers\Lichess\node_modules\rollup\dist\shared\rollup.js:198:30)
at ModuleLoader.loadEntryModule (C:\Users\hsmyers\Lichess\node_modules\rollup\dist\shared\rollup.js:22306:20)
at async Promise.all (index 0)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! lichess-oauth-app-example@ build: `rollup --config`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the lichess-oauth-app-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\hsmyers\AppData\Roaming\npm-cache\_logs\2022-11-17T00_16_59_407Z-debug.log
I believe all of this is a cascade from an improper beginning. So what do I need for a warning and error-free run? Thanks!
--hsm
I recently used the Lichess API in a project I'm working on. I managed to create an invite link to start a game, however, both the person who created the link and the person invited to play needed to click the link, which felt a bit weird and unintuitive.
I was wondering if you could help me out with some guidance on how to use invite links. ? I couldn't find an example of this in the demo. Could you provide an example or some tips on how to make this process better?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.