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

feat(portal): Add support for tlds and suins subnames #121

Merged
merged 26 commits into from
Jul 24, 2024

Conversation

Tzal3x
Copy link
Collaborator

@Tzal3x Tzal3x commented Jul 19, 2024

We are currently supporting only a pattern of domains like this 0x123.walrus.sites.

This PR makes it possible to:

  • Parse more complex domains: 0x123.localhost:8080, 0x123.walrus.co.uk
  • Support suins subnames: subsubname.subname.suinsname.walrus.sites
  • Includes some unit tests so that we can have more confidence on the function's results. Gradually we can extend our code coverage.

Connected issues:

@Tzal3x Tzal3x linked an issue Jul 19, 2024 that may be closed by this pull request
Copy link

vercel bot commented Jul 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
walrus-site ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 24, 2024 7:27am

@Tzal3x Tzal3x marked this pull request as draft July 19, 2024 15:50
@Tzal3x Tzal3x self-assigned this Jul 20, 2024
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch 2 times, most recently from 0c5eb9e to 2a53bed Compare July 20, 2024 09:26
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from 2a53bed to 3ba7ffc Compare July 20, 2024 09:27
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from 3ba7ffc to 0babe74 Compare July 20, 2024 09:27
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from 0babe74 to 89002f1 Compare July 20, 2024 09:29
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from 89002f1 to dafb3b8 Compare July 20, 2024 09:32
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from dafb3b8 to edac936 Compare July 20, 2024 09:40
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from edac936 to 2dc65c3 Compare July 20, 2024 09:42
@Tzal3x Tzal3x requested a review from giac-mysten July 20, 2024 09:43
@Tzal3x Tzal3x marked this pull request as ready for review July 20, 2024 09:46
@Tzal3x
Copy link
Collaborator Author

Tzal3x commented Jul 22, 2024

I still need to check if the suins subnames work as expected.
Converting this back to draft PR until then.

@Tzal3x Tzal3x marked this pull request as draft July 22, 2024 07:43
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch 2 times, most recently from f7d8ea6 to bb89489 Compare July 23, 2024 12:20
@Tzal3x Tzal3x force-pushed the 26-add-support-for-longer-tlds-such-as-couk branch from bb89489 to 76d204d Compare July 23, 2024 12:21
Each parse-domain release comes up with a
specific public suffix list.

We use a fixed version temporarily,
until the walrus.site gets added to the
list, and the domain_parsing.ts
 code gets updated.
@Tzal3x Tzal3x requested a review from giac-mysten July 23, 2024 12:51
@Tzal3x Tzal3x changed the title feat(portal): Add support for tlds feat(portal): Add support for tlds and suins subnames Jul 23, 2024
Copy link
Collaborator

@giac-mysten giac-mysten left a comment

Choose a reason for hiding this comment

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

Thanks @Tzal3x ! just left one comment open about merging the two functions. Please go ahead and merge if you think it is not necessary 👍

portal/src/helpers/domain_parsing.ts Show resolved Hide resolved
Copy link
Collaborator

@giac-mysten giac-mysten left a comment

Choose a reason for hiding this comment

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

Just a nit; happy for you to merge as is tho!

portal/src/helpers/domain_parsing.ts Outdated Show resolved Hide resolved
@Tzal3x Tzal3x merged commit 9aad845 into main Jul 24, 2024
15 checks passed
@Tzal3x Tzal3x deleted the 26-add-support-for-longer-tlds-such-as-couk branch July 24, 2024 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow SuiNs subdomains to work with the service worker Add support for longer "tlds" such as co.uk
3 participants