Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs/new doc #103

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Deploy to GitHub Pages

on:
# Trigger the workflow every time you push to the `main` branch
# Using a different branch name? Replace `main` with your branch’s name
push:
branches: [ doc/new-doc ] ##! need to update to master after PR
# Allows you to run this workflow manually from the Actions tab on GitHub.
workflow_dispatch:

# Allow this job to clone the repo and create a page deployment
permissions:
contents: read
pages: write
id-token: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout your repository using git
uses: actions/checkout@v4
- name: Install, build, and upload your site
uses: withastro/action@v3
path: ./new-doc/ # The root location of your Astro project inside the repository. (optional)
# with:
# node-version: 20 # The specific version of Node that should be used to build your site. Defaults to 20. (optional)
# package-manager: pnpm@latest # The Node package manager that should be used to install dependencies and build your site. Automatically detected based on your lockfile. (optional)

deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
3 changes: 1 addition & 2 deletions docs/docs/tutorial/advanced/todo.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 1
title: TODO
---

# TODO

Work in progress...
3 changes: 1 addition & 2 deletions docs/docs/tutorial/animation.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 5
title: Animation
---

# Animation

The most effective way to handle animations for various `Object3D` instances is by binding the `animate` event to each of them.

```typescript
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/asset-management.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 4
title: Asset Management
---

# Asset Management

The `Asset` class provides an efficient solution for loading and managing various resources, including 3D models, textures, and other assets in your applications.

## Resource Loading
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/binding.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 10
title: Binding
---

# Binding

You can establish property bindings for an `Object3D` in two distinct manners:
- **Automatic Recalculation:** property values are automatically updated at the conclusion of each animate cycle
- **Manual Calculation:** property values must be manually computed and updated as needed
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/drag-and-drop.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 7
title: Drag and Drop
---

# Drag and Drop

Work in progress...
3 changes: 1 addition & 2 deletions docs/docs/tutorial/events/interaction.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 0
title: Interaction
---

# Interaction

Work in progress...
3 changes: 1 addition & 2 deletions docs/docs/tutorial/events/misc.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 1
title: Miscellaneous
---

# Miscellaneous

This category encompasses animation and resize events. <br />
It's important to note that unlike `interaction events`, misc events do not follow a propagation system.

Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/events/update.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 2
title: Update
---

# Update

Update events are triggered when the value of a property or a state changes. <br />
It's important to note that unlike `interaction events`, update events do not follow a propagation system.

Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/focus-management.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 8
title: Focus Management
---

# Focus Management

Work in progress...
3 changes: 1 addition & 2 deletions docs/docs/tutorial/getting-started/configuration.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 1
title: Configuration
---

# Configuration

When transitioning from a traditional `three.js` application to `three.ez`, you'll immediately notice the central role played by the `Main` class.

The `Main` class serves as the core of your application, enabling all of `three.ez`'s features and simplifying scene and viewport rendering through convenient methods.
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/getting-started/installation.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 0
title: Installation
---

# Installation

1. Begin by creating a `three.js` project, which can be done by following the [official guide (option 1)](https://threejs.org/docs/#manual/en/introduction/Installation).
> ⚠️ **Warning** <br />
> Please note that `three.ez` is compatible with `three.js r151+`.
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/getting-started/playground.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 2
title: Playground
---

# Playground

Playgrounds let you experience `three.ez` right in your browser, with no need for installation!

They're particularly handy for:
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/index.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 0
title: Introduction
---

# Introduction

`three.ez` is a `TypeScript` library designed to streamline and enhance the development of `three.js` applications. <br />
It provides a comprehensive suite of user-friendly tools and high-performance features, making it accessible even to beginners. <br />
With `three.ez`, you'll discover an efficient and robust toolkit for your 3D projects.
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/instancedMesh2.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 12
title: InstancedMesh2
---

# InstancedMesh2

Work in progress..
3 changes: 1 addition & 2 deletions docs/docs/tutorial/migration.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 14
title: Migration
---

# Migration

Work in progress..
3 changes: 1 addition & 2 deletions docs/docs/tutorial/raycasting.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 9
title: Raycasting
---

# Raycasting

Work in progress..
3 changes: 1 addition & 2 deletions docs/docs/tutorial/rendering/how-it-works.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 0
title: How It Works
---

# How It Works

Rendering is managed through a collection of `RenderView` instances, which are internally handled within the `Main` class.

> ℹ️ **Note** <br />
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/rendering/multiple-rendering.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 1
title: Multiple Rendering
---

# Multiple Rendering

In order to render multiple distinct views, you'll need to create multiple instances of `RenderView`.

```typescript
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/rendering/smart-rendering.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
sidebar_position: 2
title: Smart Rendering
---

# Smart Rendering

Smart rendering allows frames to be rendered only when necessary, making it especially valuable for mostly static scenes. <br />
This optimization enhances performance and minimizes unnecessary computational overhead.

Expand Down
3 changes: 1 addition & 2 deletions docs/docs/tutorial/resizing.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 3
title: Resizing
---

# Resizing

Work in progress..
3 changes: 1 addition & 2 deletions docs/docs/tutorial/tweening.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
sidebar_position: 11
title: Tweening
---

# Tweening

Work in progress..
3 changes: 1 addition & 2 deletions docs/src/pages/markdown-page.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
title: Markdown page example
title: Markdown page example
---

# Markdown page example

You don't need React to write simple standalone pages.
21 changes: 21 additions & 0 deletions new-docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# build output
dist/
# generated types
.astro/

# dependencies
node_modules/

# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*


# environment variables
.env
.env.production

# macOS-specific files
.DS_Store
4 changes: 4 additions & 0 deletions new-docs/.vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"recommendations": ["astro-build.astro-vscode"],
"unwantedRecommendations": []
}
11 changes: 11 additions & 0 deletions new-docs/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"version": "0.2.0",
"configurations": [
{
"command": "./node_modules/.bin/astro dev",
"name": "Development server",
"request": "launch",
"type": "node-terminal"
}
]
}
55 changes: 55 additions & 0 deletions new-docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Starlight Starter Kit: Basics

[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)

```
npm create astro@latest -- --template starlight
```

[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/starlight/tree/main/examples/basics)
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/starlight/tree/main/examples/basics)
[![Deploy to Netlify](https://www.netlify.com/img/deploy/button.svg)](https://app.netlify.com/start/deploy?repository=https://github.com/withastro/starlight&create_from_path=examples/basics)
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fwithastro%2Fstarlight%2Ftree%2Fmain%2Fexamples%2Fbasics&project-name=my-starlight-docs&repository-name=my-starlight-docs)

> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!

## 🚀 Project Structure

Inside of your Astro + Starlight project, you'll see the following folders and files:

```
.
├── public/
├── src/
│ ├── assets/
│ ├── content/
│ │ ├── docs/
│ │ └── config.ts
│ └── env.d.ts
├── astro.config.mjs
├── package.json
└── tsconfig.json
```

Starlight looks for `.md` or `.mdx` files in the `src/content/docs/` directory. Each file is exposed as a route based on its file name.

Images can be added to `src/assets/` and embedded in Markdown with a relative link.

Static assets, like favicons, can be placed in the `public/` directory.

## 🧞 Commands

All commands are run from the root of the project, from a terminal:

| Command | Action |
| :------------------------ | :----------------------------------------------- |
| `npm install` | Installs dependencies |
| `npm run dev` | Starts local dev server at `localhost:4321` |
| `npm run build` | Build your production site to `./dist/` |
| `npm run preview` | Preview your build locally, before deploying |
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
| `npm run astro -- --help` | Get help using the Astro CLI |

## 👀 Want to learn more?

Check out [Starlight’s docs](https://starlight.astro.build/), read [the Astro documentation](https://docs.astro.build), or jump into the [Astro Discord server](https://astro.build/chat).
Loading
Loading