0.2.12-1 • Published 2 years ago

@sayduck/viewer-jellyfish v0.2.12-1

Weekly downloads
-
License
UNLICENSED
Repository
github
Last release
2 years ago

sayduck-viewer-jellyfish đŸ¦†

In this repo lives the new iteration of Sayduck's commercial 3D Viewer.

Continuous Integration

Table of Contents

  1. Usage

Our mission

This iteration of our 3D viewer fixes the pitfalls of sayduck-viewer-threejs:

  • Inter-dependency across multiple repos for our frontend code
  • Delayed display of 3D due to used design pattern
  • Heavy bundle size
  • Lack of loading priority
  • Lack of tests / cd / ci and defined processes
  • Difficulty for developers to onboard due to excessive complexity

Main goals:

  • Code Splitting
  • Modularity
  • Speed and Maintainability

Github flow and organisation

Branches

  • main - production
  • development - staging

Prefixes

  • feature/ - for features (directly tied to an issue)
  • bug/ - for bugs (directly tied to issue)
  • doc/ - for documentation, comments, etc
  • chore/ - pkg bump, test regression etc

Logs

  • BRANCHLOG - Current changes for a named branch.
  • CHANGELOG - Current changes for development branch

Code organisation

### Module based development

In an effort to reduce files size and improve readability we decided to isolate code by concerns and group each concern in its own module.

By using this method coupled with webpack we reduce the initial downloaded bundle size by only loading the necessary modules to the bootstrap of our 3D viewer. The rest of the modules are loaded on a need basis at runtime.

FIXME: add a tree dependency of the modules before release

Basic rules to follow

  1. Global

    1. Add comments only if they bring value and explain the business logic

    2. Avoid multiple purpose classes

    3. Create service classes to group shareable logic

    4. List first the attributes then the methods when writting a class

    5. List them in the order: public, protected, private

    6. add //#region private methods and //#endregion to protected and private methods

    7. When creating an empty folder use an empty .keep file

    8. When adding a file to an empty file remove the .keep file

  2. Modules

    1. Module should lay in /src/modules/${name}-module/${name}-module.ts

    2. Modules' name needs to be referenced in lowercase in the MODULE_NAME

    3. Default prototype should be default export class Foo extends Module {}

    4. See Module for abstract methods and attributes to implement in a new module

  3. Types

    1. Types used for constant values should be spelled in capital letters

    2. Don't save types inside other classes files, save them in their own file

  4. Tests

    1. Create the spec file in the same folder than the class

    2. Create a temporary spec file from the get go

    3. Add a test.todo() to not forget it later and to flag it on deploy

    4. Describe your tests file with the class you are testing.

      Example for example for the class App: app.spec.ts

      import type App from './app';
      
      describe(App, () => {
          test.todo('');
      });

Linting

We use eslint with a slightly modified version of very popular Airbnb JavaScript Style Guide coupled with our prettier

Testing

All our functional testing is done with jest. To run the tests simply execute npm test

0.2.12-1

2 years ago

0.2.11

2 years ago

0.2.10

2 years ago

0.2.8

2 years ago

0.2.7

2 years ago

0.2.6

2 years ago

0.2.6-pre-2

2 years ago

0.2.6-pre-1

2 years ago

0.2.6-pre-0

2 years ago

0.2.5

2 years ago

0.2.4

2 years ago

0.2.3

2 years ago

0.2.2

2 years ago

0.2.1

2 years ago

0.2.0

2 years ago

0.1.99

2 years ago

0.1.98

2 years ago

0.1.97

2 years ago

0.1.96

2 years ago

0.1.95

2 years ago

0.1.94

2 years ago

0.1.93

2 years ago

0.1.92

2 years ago

0.1.91

2 years ago

0.1.90

2 years ago

0.1.89

2 years ago

0.1.88

2 years ago

0.1.87

2 years ago

0.1.86

2 years ago

0.1.85

2 years ago

0.1.84

2 years ago

0.1.83

2 years ago

0.1.82

2 years ago

0.1.81

2 years ago

0.1.80

2 years ago

0.1.79

2 years ago

0.1.78

2 years ago

0.1.77

2 years ago

0.1.76

2 years ago

0.1.75

2 years ago

0.1.74

2 years ago

0.1.73

2 years ago

0.1.72

2 years ago

0.1.71

2 years ago

0.1.70

2 years ago

0.1.69

2 years ago

0.1.68

2 years ago

0.1.67

2 years ago

0.1.66

2 years ago

0.1.65

2 years ago

0.1.64

2 years ago

0.1.63

2 years ago

0.1.48

2 years ago

0.1.47

2 years ago

0.1.43

2 years ago

0.1.38

2 years ago

0.1.37

2 years ago

0.1.36

2 years ago

0.1.35

2 years ago

0.1.28

2 years ago

0.1.27

2 years ago

0.1.26

2 years ago

0.1.25

2 years ago

0.1.24-debug-01

2 years ago

0.1.24

2 years ago

0.1.12-temp-3

2 years ago

0.1.12-temp-2

2 years ago

0.1.12-temp

2 years ago

0.1.0

3 years ago

0.0.19

3 years ago

0.0.18

3 years ago

0.0.17

3 years ago

0.0.16

3 years ago

0.0.15

3 years ago

0.0.14

3 years ago

0.0.13

3 years ago

0.0.12

3 years ago

0.0.11

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago