Skip to content

[WIP] improvement: use jaspr to render html page#76

Merged
passsy merged 10 commits into
passsy:mainfrom
schultek:jaspr-timeline
Dec 12, 2024
Merged

[WIP] improvement: use jaspr to render html page#76
passsy merged 10 commits into
passsy:mainfrom
schultek:jaspr-timeline

Conversation

@schultek
Copy link
Copy Markdown
Contributor

@passsy What do you think?

Just the proof of concept for now, can be improved.

@passsy
Copy link
Copy Markdown
Owner

passsy commented Nov 22, 2024

Awesome! I was a bit worried that rendering would take too long. I measured 35ms. That's a tax I'm willing to pay!

I already feel more confident writing logic in Jaspr vs plain HTML/CSS. I'm happy to take it over from here ✌️

@schultek
Copy link
Copy Markdown
Contributor Author

schultek commented Nov 22, 2024

Very cool.

I'm setting up the client logic right now, give me another day then you can take over 😊

@schultek
Copy link
Copy Markdown
Contributor Author

Now its fully migrated, Jaspr renders both server-side (the html generation) and client side (the interactivity).

To keep the setup simple, I added a tooling script that compiles the client-side code to js and places it in the script.js.dart file. So whenever the client-side code is modified, run dart run tool/compile_js.dart.

For now I just mirrored the exact design and functionality of the existing website, but I'm happy to help with improving this as a follow up if you want.

Comment thread lib/src/timeline/html/print_html.dart
Comment thread lib/src/timeline/html/web/run_app.dart Outdated
Comment thread lib/src/timeline/html/web/app.dart Outdated
Comment thread lib/src/timeline/html/web/app.dart Outdated
Comment thread lib/src/timeline/html/web/app.dart Outdated
Comment thread lib/src/timeline/html/web/run_app.dart Outdated
Kilian Schulte added 2 commits November 25, 2024 19:46
…o jaspr-timeline

# Conflicts:
#	lib/src/timeline/html/print_html.dart
#	lib/src/timeline/html/web/timeline_app.dart
@schultek schultek marked this pull request as ready for review November 25, 2024 18:51
@schultek schultek requested a review from passsy November 25, 2024 18:51
@passsy passsy merged commit 985c14d into passsy:main Dec 12, 2024
@passsy
Copy link
Copy Markdown
Owner

passsy commented Dec 12, 2024

Thanks so much @schultek for your efforts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants