Как устроен сайт
Сайт «Доки» работает на базе Eleventy. При помощи Nunjucks-темплейтов Eleventy превращает статьи в формате Markdown в HTML-страницы.
Проект собирается с помощью GitHub Actions и хостится на сервере, читайте подробнее про деплой.
https://github.com/doka-guide/platform#%D0%BA%D0%B...
const offscreenCanvas = document.createElement('canvas');
const offscreenCtx = offscreenCanvas.getContext('2d');
function drawItems() {
offscreenCtx.clearRect();
items.forEach(item => {
offscreenCtx.beginPath();
offscreenCtx.arc(item.x, item.y, item.r, 0, 2 * Math.PI);
offscreenCtx.fill();
offscreenCtx.stroke();
});
}
drawItems();
window.addEventListener('mousemove', (e) => {
if (!shouldMoveCanvas) return;
ctx.translate(e.movementX , e.movementY);
ctx.drawImage(offscreenCanvas, 0, 0);
}, false);