Code Monkey home page Code Monkey logo

fabric's Introduction

Hi, I'm Eryn! I work on a lot of different things, including developer tooling, libraries, websites, and games!

I'm a self-taught engineer with a passion for learning new things. I love going down the rabbit hole of learning the ins and outs of something that's new and exciting, and taking that experience with me onto the next thing. I also love teaching and helping other engineers with any problems they might have!

I've created or contributed to hundreds of projects using a wide breadth of technologies and patterns that I've learned along the way. I've worked on games (in Roblox and other engines), websites (both front end and back end), bots & automation, command line tools, add-ons & mods for various games, and all sorts of miscellaneous adventures. I believe that the best results can be achieved when you take experience and wisdom from many different places into account when creating something new.

If you're interested in seeing some my projects outside of work, check out my portfolio website: eryn.io

fabric's People

Contributors

evaera avatar ok-nick avatar sayhisam1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

fabric's Issues

Client componets don't need to unsubscribe when ref is destroyed

  1. destroy part on server
  2. component on server destroyed
  3. component on client destroyed (independently of server, since it uses collectionservice)
  4. component on client tries to tell server something, (i'm assuming unsubscribe) but error on server since cannot deserialize already destroyed component on part

exportLayers and addManyLayers

Map of

:exportLayers returns map of layer scope -> layer data. The map does NOT contain layers whose scope is a table.

{
  {
    layerNameString = layerData
  },
  ...
}

:addManyLayers restores this data structure into the component as layers

Extension for making events / intervals easier

Very vague for now. Not sure how I want this to work yet.

But basically, there should be an optional extension that makes running some code on every event (like Heartbeat, RenderStepped, etc) or on an interval easy.

There should only be one cycle per component type. Meaning if you have multiple "Door" components, and the component has a Heartbeat event setup, there's only ever one Heartbeat connection, and all Doors update sequentially.

This is good for performance reasons as opposed to creating a new event for each and every component.

Effects reactor discussion

Method 1 (current)

The effects currently track what :get() calls you use inside of them to determine what keys need to be tracked. This works because all effects run when onAdded fires.

Pros:

  • Automatic optimization of keys to access
  • Can access keys from other components and it works just the same

Cons:

  • If the user puts any :get() calls behind different code paths, some of them might not get hooked correctly. This is a potential source of mistakes.
  • If there's an error when the effect first runs, it won't be able to track keys that were supposed to be accessed behind the error.

Method 2 (proposed)

An alternative would be to make the user explicitly pass which keys they want to re-run the effect for.

Pros:

  • Makes the two above potential mistakes impossible
  • onAdded event can be removed, because that's just the same as an event with no keys being watched
  • More flexible in that you could re-run the effect when a key that you don't even access changes.

Cons:

  • Can't access keys from other components in a natural way
  • Optimization is now opt-in

Questions:

  • Should we pass the listed keys to the function handler as a convenience, or should we make the user access the keys manually?

If we switch to method 2, how do we access data from other components? Should we invent a special object you pass to the key tracking list in place of a key, that includes the key, ref, and component that you want to access?

create extension

create method which returns an “uncreate” function. This will allow hot reloading to create stuff.

shorthand for self:on("destroy", cb)

Connectables

Facilitate components communicating with events in a way that's statically configurable. This means that a Studio plugin would be able to be created, which for example allows you to connect a part with a Button component to a part with a Door component. The Button "press" event could be connected to the door's "open" method.

Replication removal

If server -> client with nil data, client component gets removed. This means if the server component ever gets created again later, the client component will never come back.

Roact extension

FabricLib.useRoact(fabric, roact)

Mount a roact tree on the ref if the component contains a render function: on component create, we mount if render exists, then call render. on destroy, unmount

{} = nil

Empty table should be the same as passing nil to a layer

Event connections leak memory

local weakSelfContainer = setmetatable({ self = self }, { __mode = "v" }) then use weakSelfContainer.self in the disconnect callback

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.