[O] Optimize imports
This commit is contained in:
@@ -1,14 +1,13 @@
|
|||||||
import * as THREE from 'three'
|
import * as THREE from 'three'
|
||||||
|
import {Color} from 'three'
|
||||||
import * as helper from "@/animation/Helpers"
|
import * as helper from "@/animation/Helpers"
|
||||||
import {circle} from "@/animation/Helpers"
|
import {initMouseTracker} from "@/animation/Trackers"
|
||||||
import {initMouseTracker, moused} from "@/animation/Trackers"
|
|
||||||
import {addDirLight, addGround, addHemiLight, addSky} from "@/animation/Shaders"
|
import {addDirLight, addGround, addHemiLight, addSky} from "@/animation/Shaders"
|
||||||
import {colors, config} from "@/animation/Config"
|
import {config} from "@/animation/Config"
|
||||||
import Cursor from "@/animation/components/Cursor";
|
import Cursor from "@/animation/components/Cursor";
|
||||||
import IUpdatable from "@/animation/components/IUpdatable";
|
import IUpdatable from "@/animation/components/IUpdatable";
|
||||||
import Grid from "@/animation/components/Grid";
|
import Grid from "@/animation/components/Grid";
|
||||||
import Editor from "@/animation/components/Editor";
|
import Editor from "@/animation/components/Editor";
|
||||||
import {Color} from "three";
|
|
||||||
|
|
||||||
export let renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.PerspectiveCamera
|
export let renderer: THREE.WebGLRenderer, scene: THREE.Scene, camera: THREE.PerspectiveCamera
|
||||||
export let editor: Editor
|
export let editor: Editor
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import * as THREE from 'three'
|
import * as THREE from 'three'
|
||||||
|
import {DirectionalLight, HemisphereLight, Mesh} from 'three'
|
||||||
import {colors, config} from "@/animation/Config";
|
import {colors, config} from "@/animation/Config";
|
||||||
import {DirectionalLight, HemisphereLight, Mesh} from "three";
|
|
||||||
|
|
||||||
export const vertexShader = `
|
export const vertexShader = `
|
||||||
varying vec3 vWorldPosition;
|
varying vec3 vWorldPosition;
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import {Color, Material, Mesh, MeshBasicMaterial, Object3D, Vector3} from "three";
|
import {Mesh, MeshBasicMaterial, Vector3} from "three";
|
||||||
import IUpdatable from "@/animation/components/IUpdatable";
|
import IUpdatable from "@/animation/components/IUpdatable";
|
||||||
import {circle} from "@/animation/Helpers";
|
import {circle} from "@/animation/Helpers";
|
||||||
import {camera, scene} from "@/animation/Home";
|
import {scene} from "@/animation/Home";
|
||||||
import {moused, projectTo3D} from "@/animation/Trackers";
|
import {moused, projectTo3D} from "@/animation/Trackers";
|
||||||
import {config} from "@/animation/Config";
|
import {config} from "@/animation/Config";
|
||||||
import {minMax} from "@/scripts/utils";
|
import {minMax} from "@/scripts/utils";
|
||||||
|
|||||||
@@ -29,12 +29,11 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import {Options, Vue} from 'vue-class-component';
|
import {Options, Vue} from 'vue-class-component';
|
||||||
import {Prop, Watch} from "vue-property-decorator";
|
import {Prop, Watch} from "vue-property-decorator";
|
||||||
import {hosts} from "@/scripts/constants";
|
import {$, hosts} from "@/scripts/constants";
|
||||||
import {marked} from "marked";
|
import {marked} from "marked";
|
||||||
import Tag from "@/components/Tag.vue";
|
import Tag from "@/components/Tag.vue";
|
||||||
import moment from "moment";
|
import moment from "moment";
|
||||||
import {pushQuery} from "@/scripts/router";
|
import {pushQuery} from "@/scripts/router";
|
||||||
import {$} from '@/scripts/constants';
|
|
||||||
|
|
||||||
export interface BlogPost
|
export interface BlogPost
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ import "vue3-colorpicker/style.css";
|
|||||||
import {ColorPicker} from "vue3-colorpicker";
|
import {ColorPicker} from "vue3-colorpicker";
|
||||||
import {range} from "@/scripts/utils";
|
import {range} from "@/scripts/utils";
|
||||||
import {Emit, Model, Prop, Ref} from "vue-property-decorator";
|
import {Emit, Model, Prop, Ref} from "vue-property-decorator";
|
||||||
import {Vue, Options} from "vue-class-component";
|
import {Options, Vue} from "vue-class-component";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Mouse Usage:
|
* Mouse Usage:
|
||||||
|
|||||||
@@ -8,7 +8,6 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import {Options, Vue} from 'vue-class-component';
|
import {Options, Vue} from 'vue-class-component';
|
||||||
import MyColorPicker from "@/components/color/ColorPicker.vue";
|
import MyColorPicker from "@/components/color/ColorPicker.vue";
|
||||||
import {Color} from "three";
|
|
||||||
|
|
||||||
@Options({components: {MyColorPicker}})
|
@Options({components: {MyColorPicker}})
|
||||||
export default class Projects extends Vue
|
export default class Projects extends Vue
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
import {
|
import {createRouter, createWebHistory, NavigationFailure, RouteRecordRaw} from 'vue-router'
|
||||||
createRouter,
|
|
||||||
createWebHashHistory,
|
|
||||||
createWebHistory,
|
|
||||||
NavigationFailure,
|
|
||||||
RouteRecordRaw
|
|
||||||
} from 'vue-router'
|
|
||||||
import Home from '../views/Home.vue'
|
import Home from '../views/Home.vue'
|
||||||
|
|
||||||
const routes: Array<RouteRecordRaw> = [
|
const routes: Array<RouteRecordRaw> = [
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import {Options, Vue} from "vue-class-component";
|
import {Vue} from "vue-class-component";
|
||||||
import {withKeys} from "vue";
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Same as python's range
|
* Same as python's range
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import {Options, Vue} from 'vue-class-component';
|
import {Options} from 'vue-class-component';
|
||||||
import {camera, editor, objects, start} from "@/animation/Home";
|
import {camera, editor, objects, start} from "@/animation/Home";
|
||||||
import {config} from "@/animation/Config";
|
import {config} from "@/animation/Config";
|
||||||
import {KeyHandler, range} from "@/scripts/utils";
|
import {KeyHandler, range} from "@/scripts/utils";
|
||||||
|
|||||||
Reference in New Issue
Block a user