/
githubmirror
/
pixijs
Обзор
Документация
Войти
/
githubmirror
/
pixijs
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
dev
playground/src/default.playground.ts
17 строк
472 B
Mat Groves
chore: Add PixiJS development playground (#11878)
12 фев 2026, 18:26
Не верифицирован
12 фев 2026, 18:26
d0c73cf
Код
Авторство
О чём код?
import { Application, Assets, Sprite } from 'pixi.js'; export default async function init() { const app = new Application(); await app.init({ background: '#1099bb', resizeTo: window }); document.body.appendChild(app.canvas); const texture = await Assets.load('assets/bunny.png'); const bunny = new Sprite(texture); bunny.anchor.set(0.5); bunny.x = app.screen.width / 2; bunny.y = app.screen.height / 2; app.stage.addChild(bunny); }