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

[WIP] v0.2.5 #26

Merged
merged 173 commits into from
May 10, 2023
Merged

[WIP] v0.2.5 #26

merged 173 commits into from
May 10, 2023

Conversation

reyamir
Copy link
Collaborator

@reyamir reyamir commented Apr 19, 2023

Changelog

Newsfeed:

  • Refactor event collector
  • Merge init data page (pre-data fetching) to index page (splashscreen)
  • Overhaul newsfeed data fetcher, fixed duplicate notes and loading new note issue
  • Add reusable content parser, clean code, no more duplicate function
  • NIP-18: add kind 6 to newsfeed, thank @smolgrrr for initial work
  • NIP-18: add repost button

Channels:

  • NIP-28: support kind 40, 41, 42 ,43 and 44
  • New UI for channels message page
  • New UI for channel creation
  • Add default channel list, includes lume-general and nostr channel
  • Add useChannelMetadata hook, if kind 41 content present, lume will use it instead of kind 40 content
  • New UI for channels explore page (postpone to next version)

Chats:

  • New UI for chats message page

Messages (chat/channel):

  • Add messageParser, support link highlight and image/video preview
  • Refactor message (channel/chat) store, 20% faster than before

Others:

  • Migrated from Nextjs to Vite + Vite Plugin SSR
  • Update default relay list, reduce network usage about 80% and lower CPU and RAM usage
  • Use iconoir for consistent icon system
  • Refactor useMetadata hook and change name to useProfileMetadata, fetch saved metadata first, if not saved, fetch from https://rbr.bio then saved
  • Add network status (online/offline)
  • Ensure only one app instance running, using tauri-single-instance plugin
  • Move back to tauri-sql-plugin, completed remove prisma-client-rust
  • Disable prefetch for link component
  • Migrated from radix-ui to headless-ui
  • Refactor editor (note/message form), support direct image upload, new and lightweight emoji picker
  • Native notification
  • Tauri updater
  • Optimize bundle size, lume bundle size around 9.7MB
  • Add dev guide
  • Update README

Dev diary

Multiple root layouts
Due to this bug 48260, I've to use /nostr/ path instead of route groups for multiple root layouts

Prisma Client Rust
I've made a mistake when migrate from tauri-sql to prisma-client-rust, due to this bug 6723, production build won't launch

Why I choose prisma-client-rust first time, with it I can manage database at scale, migration is feature that I need. But after that, I realise it isn't easy, at least with me, due to lack of rust knowledge, many bugs and issues that I can't handle

So I choose go back with tauri-sql, which is safer option

Browse channels
I want to create a discover page, something like discord but for nostr channels, but currently list include a lot of spam channel. I will working on other service, which fetch all channels and apply some filter for spam channel, I also add cataloging for channel

Nexjs 13 appDir and Tauri
Today, I've reliase nextjs 13 appdir can export to html, but it don't play nice with Tauri, prefetch feature of nextjs cause bug in Tauri, if link is prefetched, Tauri will load *.txt file instead of .html file from export folder

Default relay list

  • wss://welcome.nostr.wine
  • wss://relay.nostr.band
  • wss://nostr.mutinywallet.com

Current resource usage

  • Disk: 10MB
  • RAM: 150 - 300MB
  • CPU: 5 - 10%
  • Network: xxx

@reyamir reyamir merged commit e7bcf6c into main May 10, 2023
@reyamir reyamir deleted the canary branch May 19, 2023 02:10
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.

None yet

1 participant