Giter Club home page Giter Club logo

cycle-regl's Introduction

Cycle.js Community

This organization is a place for any Cycle.js project that welcomes collaboration. We welcome all types of projects, from drivers to games to documentation to art.

The official cyclejs organization contains the code for Cycle.js itself and the core libraries developers might use. (HTTP, DOM, etc). We're here for all of the cool stuff the community makes.

About our community

We are a welcoming, collaborative community. We believe that contributions should be encouraged and celebrated. We especially welcome those who feel like they might not be welcome, or able to help. Come one, come all.

We do not tolerate behaviour that makes other contributors feel harassed or unwelcome. Please see the code of conduct.

In short, don't be a dick and consider how others will perceive your actions. If you experience any negative interactions, please contact either @tylors or @widdershin and we will do our best to help. If in doubt, get in touch.

Getting involved

We welcome contributors of all levels of experience and from all different backgrounds.

We are liberal about membership. If you want to be a member, please open an issue on this repository and we will add you. ๐Ÿ˜„

As a member, you are welcome to create repositories in this community and to transfer your existing repos. The only criteria is that they're related to Cycle.js and that collaboration is welcomed.

The most straightforward way to contribute to a repository is to open a pull request. We ask that repositories in our community follow Github flow as using pull requests allows for more review, discussion and learning to take place.

When one of your pull requests is merged, you will be added as a collaborator to the repository. This allows for easier collaboration (as collaborators can work together on pull requests).

Being a collaborator means:

  • You can push to the repo, and to branches.
  • With the permission of the other collaborators, you can merge pull requests.
  • You get to have a say in the development of the project.
  • You have no obligation to contribute, but any work you do is very appreciated.
  • You still work with pull requests, but now you work on the repo itself, not your fork. This makes it easier to collaborate.

Here is an automagically generated list of open, unassigned issues with a "Help Wanted" label. If you want to contribute but you're unsure what to work on, take a look at these issues and comment on any you're interested in.

cyclic-router

cycle-canvas

README

cycle-svg-pan-and-zoom

cycle-regl

cycle-regl's People

Contributors

widdershin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

cycle-regl's Issues

Clean up DOM when using `container` option upon re-running or Cycle `.dispose()` being called

When the Cycle instance running this driver calls .dispose() (e.g. in response to cycle-restart receiving a HMR update) any generated elements/objects should be cleaned up, this already happens implicitly when using the fullscreen automatic element or the canvas option as Regl directly replaces those elements when running the next time, but if specifying container you end up with multiple canvas elements. This might be the intended behaviour, I'm just opening it as an issue because it's not the behaviour I expected.

For example, if you use something like this and get a HMR update:

makeReglDriver({
  container: document.getElementById('viewport')
}),

canvas elements from previous executions will remain inside the #viewport element, a new canvas with the new result is appended to #viewport.

My guesses for a potential solution would be one of:

  • When options.container is set:
    • Hard: Unset the container's children as an explicit cleanup step, only removing children that were created by this driver, this will require the driver to track the elements regl creates.
    • Easy: Clear all of the container element's children out prior to calling setupRegl.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.