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

(Not) enums on steroids #90

Open
ssukienn opened this issue Feb 19, 2023 · 6 comments
Open

(Not) enums on steroids #90

ssukienn opened this issue Feb 19, 2023 · 6 comments
Labels

Comments

@ssukienn
Copy link

  • Your full name: Szymon Sukiennik
  • Target audience (beginner/intermediate/advanced/everyone): intermediate
  • Estimated duration: 15-25 min
  • Keywords: enum-like, dictionary objects, const assertion objects, satisfies, guards, mapped types, reverse mapped types

(Not) enums on steroids

The talk

One-sentence summary

The subjective approach of treating enum-like object dictionaries as an in-memory shared API of application dictionary like state

What's the format — is it a case study, a live coding session, a workshop or something else?

Case-study. Introduction to the problem space, explanation of required TS constructs, going through existing minimal implementation, small living code in playground/IDE to showcase the result.

Tell us more about the talk

  1. Brief introduction to enum shenanigans in TS and how they compile and behave (to later forget about them as they won't be used) vs const assertions.
  2. Brief discussion of problem space for managing dictionary-like state in the API, persistent layer, exposing it to the FE, pitfalls, and where I come from with it
  3. Going through TS constructs important for understanding: conditional types, mapped types, reversed mapped types, const assertion objects, satisfies operator. No deep dives, just enough knowledge
  4. Introducing the approach of creating simple or composite dictionary objects and how to work with them
  5. Limitations & possibilities

You

A few words about yourself

My name is Szymon Sukiennik and I am a software developer with various interests in different areas of the software stack, recently mainly focused on the backend, distributed systems and observability.

How can we find you on social media?

@ssukienn on Twitter or by email

Would you be willing to have a Q/A session after the talk?

Sure

Do you mind if we record the event?

Nope

Is there anything we can help you with?

Review slides, add feedback



Hey! I checked that there is already some similar talk proposal (#88). Not sure how significant the overlap would be here. Though, I use mapped/remapped types only as a tool to achieve typesafe remappings. Otherwise, my talk would focus on a subjective approach of treating enums like data in the project :) I am happy to propose something else if you think it will be too much of a conflict. Cheers!

@welcome
Copy link

welcome bot commented Feb 19, 2023

Thanks for your contribution! One of the @WrocTypeScript/organisers will go back to you as soon as possible.

@ssukienn ssukienn changed the title (Your talk title) (Not) enums on steroids Feb 19, 2023
@karol-majewski
Copy link
Member

karol-majewski commented Feb 20, 2023

Thank you for your contribution @ssukienn!

It would be a pleasure to have a talk about enums and their alternatives. There seems to be so much confusion about them amongst TypeScript programmers. This topic definitely deserves attention!

As for #88, I guess we're going to see how much the talks overlap on Wednesday ;) We can revisit the topic then and decide on the next steps if that's alright with you.

@ssukienn
Copy link
Author

Definitely, I won't attend the meeting this Wednesday but happy to watch it and discuss this one at a later time 👌 Thanks for the response!

@karol-majewski
Copy link
Member

Here's the recording from yesterday.

I don't think there is too much overlap — the talk Mateusz gave was focused on type layer transformations rather than dictionaries as such.

Please let us know what you think 🙇

@ssukienn
Copy link
Author

ssukienn commented Apr 6, 2023

Hi,

Huge apologies for the delay here and for not responding earlier. Recently was and am super occupied by personal matters and also related to switching roles and company.

I watched the video and it seems that the next similar meeting would take place in May/June? I'm not sure if things will stabilize enough so I can spend some time preparing it before the next one so np if s1 would like to take over a similar one. Will let you know when I would have smth ready :)

On the topic. Ye, the overlap is not that big, and actually would probably change it a little. To touch enums in bigger deep dive and explain all the confusement around using them or normal objects. Then glue it with this issue proposal which did not intend to go into enums too much.

Thanks, take care!

@karol-majewski
Copy link
Member

Thanks for getting back to us 🙇🏻

Our next meetup will probably take place around the end of June. So there is still quite some time to decide on the scope of your talk. No need to rush anything ☺️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants