Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

The LWJGL 3 website.

License

NotificationsYou must be signed in to change notification settings

LWJGL/lwjgl3-www

Repository files navigation

lwjgl3-www docker

lwjgl.org - Home of Lightweight Java Game Library

The website for LWJGL is build with React. It is a single-page application with client-side routing. It installs a Service Worker in order to work offline.

Notable features:

  • Client-siderouting
  • Service Worker (works offline)
  • Tiny production build (entire codebase + content weights less than 300KB gzipped)
  • Code splitting at route & component level
  • Scroll restoration
  • Route preloading
  • Proximity based route preloading (see /download page)
  • Build Customizer with smart download queue & client-side ZIP generator
  • Customwebpack manifest parsing + code minification
  • CSS-in-JS withStitches
  • Client is written inTypescript

Warning:

There is currently no server-side rendering because of hosting constraints.

Dependencies

Static assets are loaded from LWJGL's CDN (AWS CloudFront).

Build status icons are loaded directly fromtravis-ci.org andappveyor.com.

Three.js is loaded fromjsDelivr.

Prerequisites

Development

Install all required npm packages and build styles:

#corepack enablepnpm inode --run build:styles

Start the server in dev mode:

node --run start

CLI flags

The following flags are used for testing production builds locally.NODE_ENV environment variable must be set to "production".

--test# Enables production test mode (e.g. disables HSTS)--nocache# Disables Pug view caching--pretty# Pretty prints HTML--s3proxy# Proxies S3 images

Environment variables

NODE_ENV="production"# default: developmentPORT="8080"# default: 80HOST="127.0.0.1"# default: 0.0.0.0

Codebase Diagram

Visualization of the codebase

Production

To deploy LWJGL in production please read the separate guide:DEPLOYMENT.md.

Testing production builds

git pullpnpm inode --run release

You can run the production build locally:

node --run dev:test-production

Debugging production output

The following debugging tips may come in handy:

  • Disable minification by uncommentingminimize: false inwebpack.config.js
  • Prevent Terser from droppingconsole.log ordebugger by changingterserOptions interser-config.json
  • SetPROFILING=1 env variable to load React profiling builds
  • Outputnamed module & chunk ids inwebpack.config.js
  • Analyze build output withnpx webpack-bundle-analyzer public/js/build.manifest.json -h 0.0.0.0 (for full breakdown, change toall: true when writingbuild.manifest.json inbuild-production.js)

Other LWJGL subdomains:

  • The website for LWJGL 2 can be foundhere. A static copy of the old LWJGL website is now hosted directly from S3
  • The blog is powered byGhost.
  • The forum isSMF.
  • The wiki for LWJGL 2 wasMediaWiki. A static copy of the old LWJGL wiki is now hosted directly from S3.

[8]ページ先頭

©2009-2025 Movatter.jp