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

New extension: Webhooks (TurboHook replacement) #1873

Open
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

CubesterYT
Copy link
Member

Hello all!

The time has finally come, the long awaited successor to the horrendous extension that is "TurboHook". Under code name "TurboHook V2", this extension took time to develop as I waited for certain APIs to happen (extension storage my beloved), and also just forgetting about the extension in the first place 😅. I deemed it smart to make this a whole new extension entirely, and TurboHook will now be hidden.

Video Example:

2025-01-16.23-49-59.mp4

Honestly, I'm going to consider this extension my Magnum Opus at the moment, since this represents my growth since I first contributed here. The difference between TurboHook and this extension is insane.

@CubesterYT CubesterYT requested a review from a team January 17, 2025 06:43
@github-actions github-actions bot added the pr: new extension Pull requests that add a new extension label Jan 17, 2025
@CubesterYT CubesterYT requested a review from a team January 18, 2025 00:14
Copy link
Collaborator

@SharkPool-SP SharkPool-SP left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems good now

Thebloxers998

This comment was marked as abuse.

@CubesterYT CubesterYT requested a review from a team January 18, 2025 21:12
extensions/CubesterYT/Webhooks.js Outdated Show resolved Hide resolved
extensions/CubesterYT/Webhooks.js Outdated Show resolved Hide resolved
extensions/CubesterYT/Webhooks.js Outdated Show resolved Hide resolved
extensions/CubesterYT/Webhooks.js Show resolved Hide resolved
@CubesterYT CubesterYT requested a review from a team January 19, 2025 03:03
Copy link
Member

@yuri-kiss yuri-kiss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

last change then im gonna review the docs

extensions/CubesterYT/Webhooks.js Show resolved Hide resolved
Copy link
Member

@GarboMuffin GarboMuffin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you need to await prompt() so that it works in the desktop app

ill read the rest of it later today

@CubesterYT
Copy link
Member Author

CubesterYT commented Jan 20, 2025

you need to await prompt() so that it works in the desktop app

ill read the rest of it later today

OHHHH SO THAT'S WHY IT BROKE IN THE DESKTOP APP DURING MY TESTING

I'll get to fixing it

…ense since it wont be null when restoring storage that already exists
@GarboMuffin GarboMuffin changed the title Webhooks extension (The defacto TurboHook replacement) New extension: Webhooks (TurboHook replacement) Jan 20, 2025
@GarboMuffin
Copy link
Member

GarboMuffin commented Jan 20, 2025

  1. make a project with a webhook
  2. save it
  3. reload the page
  4. load saved project
  5. all the blocks are still hidden

@GarboMuffin
Copy link
Member

dont like how empty try/catch is being used everywhere to handle errors

as it is right now a project can make a block that contains something like toString as the menu name and then store data on Object.prototype.toString.DATA and Object.prototype.toString.TYPE which probably doesn't break anything but it's definitely not great to do that. better to check if the webhook exists first

@GarboMuffin
Copy link
Member

TurboHook still has functionality that this doesn't have, specifically the ability to send to arbitrary webhooks not known until runtime

@CubesterYT
Copy link
Member Author

TurboHook still has functionality that this doesn't have, specifically the ability to send to arbitrary webhooks not known until runtime

I'm confused, what do you mean by this?

@GarboMuffin
Copy link
Member

image

@CubesterYT
Copy link
Member Author

CubesterYT commented Jan 20, 2025

Ah, I see
The plan with this remake is to only store webhooks, but not defined till runtime. I could make adjustments...

By the way, all these things in TurboHook like content, image, and whatever only work with Discord and Discord similar syntax Webhooks, meaning it's not at ALL like how Webhooks in general work. It's only like this since it started as a Discord Webhook extension.

@CubesterYT CubesterYT requested a review from a team January 20, 2025 20:56
@Brackets-Coder
Copy link

I really like this extension idea. TW web hooks could change the way we do things... I'll be waiting.

@GarboMuffin
Copy link
Member

This is for sending webhooks, which is already possible, this is just a more elegant way

Do you want webhooks the other direction?

@CubesterYT
Copy link
Member Author

This is for sending webhooks, which is already possible, this is just a more elegant way

Do you want webhooks the other direction?

@GarboMuffin I think I mentioned this in passing a year ago during TurboHook, but I had an idea where we could have our own webhook system as well to allow users to make their own Webhooks and receive data. We could incorporate this with this extension.

@Brackets-Coder
Copy link

This is for sending webhooks, which is already possible, this is just a more elegant way

Do you want webhooks the other direction?

Yes, I'm aware it was already possible, I'm just remarking at how much better this extension is than TurboHook

I think webhooks in both directions would be fantastic

@yuri-kiss
Copy link
Member

Ah, I see The plan with this remake is to only store webhooks, but not defined till runtime. I could make adjustments...

By the way, all these things in TurboHook like content, image, and whatever only work with Discord and Discord similar syntax Webhooks, meaning it's not at ALL like how Webhooks in general work. It's only like this since it started as a Discord Webhook extension.

You could make a temporary webhook block to "polyfill" the usage of the old turbohook block if needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: new extension Pull requests that add a new extension
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants