Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Apr 24 21:47

    ai on main

    Fix nano-staged config (compare)

  • Apr 24 21:45

    ai on main

    Update CI, dependencies and lin… (compare)

  • Mar 26 12:38

    ai on main

    Update CI config (compare)

  • Mar 26 12:37

    ai on main

    Update dependencies (compare)

  • Jan 10 06:45

    ai on main

    Fix spelling check (compare)

  • Jan 10 06:42

    ai on main

    Promote Vite instead of Parcel Update dependencies (compare)

  • Dec 23 2021 23:41

    ai on main

    Fix remark plugins (compare)

  • Dec 23 2021 23:37
    ai commented #90
  • Dec 23 2021 23:36

    ai on main

    Update dependencies Add ignore-scripts to yarn in D… Move from Yarn to pnpm (compare)

  • Dec 23 2021 23:24

    ai on main

    Adds recipe about deployment (#… (compare)

  • Dec 23 2021 23:24
    ai closed #90
  • Dec 22 2021 17:49
    vitalybaev synchronize #90
  • Dec 22 2021 16:39
    vitalybaev edited #90
  • Dec 22 2021 16:38
    vitalybaev opened #90
  • Nov 21 2021 17:58

    ai on main

    Clean up dependencies (compare)

  • Sep 28 2021 20:35
    ai commented #89
  • Sep 28 2021 18:01
    vitalybaev commented #89
  • Sep 28 2021 17:26

    ai on main

    Updated example of Logux Server… (compare)

  • Sep 28 2021 17:26
    ai closed #89
  • Sep 28 2021 17:26
    ai commented #89
Michael Floering
@floering:matrix.org
[m]
(i'm testing this myself, but asking in the meantime 🙂)
Jeremy Dombrowski
@meatflavourdev

quick question - does anybody know if logux "just works" in a browser extension? (i.e. using sendMessage)

Not too familiar, but I'd check out
https://logux.io/web-api/#crosstabclient

Then you can just listen for messages and in the handler add them to the log(?)

client.log.add({ type: 'logux/subscribe', channel: 'users/14' }, { sync: true })
client.log.add({ type: 'logux/unsubscribe', channel: 'users/14' }, { sync: true })
"IndexedStore to store Logux log in IndexedDB" sounds handy.
https://github.com/logux/client
Michael Floering
@floering:matrix.org
[m]
@meatflavourdev: 👍️ thank you for the tips!
Michael Floering
@floering:matrix.org
[m]
have a question about nanostores, since it was a renaming from logux/state
Michael Floering
@floering:matrix.org
[m]

if i'm using CrossTabClient from @logux/client, with IndexedStore, and i've installed using the command npm install @logux/core @logux/client nanostores ... is it good/bad/ugly to use nanostores as well? it feels like a smell if i use it directly, if i try to have my authoritative state live in Logux (CrossTabClient, IndexedStore), but also have separate usage of nanostores.

but i'm using Svelte, and the nanostores README makes a lot of sense to me. so i'm trying to figure out - can I use nanostores the way it's outlined in the nanostores README, but use it together with CrossTabClient?

3 replies
Michael Floering
@floering:matrix.org
[m]
Cool, makes sense to me. Thank you much!
Dominik Picker
@DaDom
Hi!
I have a question about executing actions in batch:
Imagine I would like to dispatch multiple actions in one go, and those might even be a mix of local and sync. The regular batch util coming with react-redux does not really help with that. And it seems to me that when dispatching all actions just one by one (without await), there is a lot of time-travel going on.
Is there a recommended way how to handle that?
9 replies
Jules ➐
@legarsjules_twitter
Hello, I would like to use logux with nanostores like app state manager. I would like to know if I need to implement time travel system when receive undo or if an implementation like for redux or vuex was developed ?
17 replies
Dominik Picker
@DaDom
Hi!
Is there a way to use encodings like gzip or brotli for the websocket communication?
If not, what would be the best place to inject something like that?
Thanks a lot!
4 replies
fx
@dynamitec.fs:matrix.org
[m]
I am evaluating Logux at the moment and wonder if it is also possible to do a replay of previous events as with a read model in classic CQRS/ES.
1 reply
fx
@dynamitec.fs:matrix.org
[m]
I want to regenerate the current state after changes.
2 replies
fx
@dynamitec.fs:matrix.org
[m]
:point_up: Edit: I want to regenerate the current state after changes how actions are processed - replaying all previous events.
Is that easier to understand?
:point_up: Edit: I want to regenerate the current state after changing how actions are processed - replaying all previous events.
:point_up: Edit: I want to regenerate the current state after changing how actions are processed - replaying all previous actions.
Ilya Radchenko
@knownasilya
Can types be contained to a channel? Seems like a missed opportunity for contextual/grouped types.
6 replies
Ilya Radchenko
@knownasilya
Where do people host their logux server?
1 reply
Eduard Aksamitov
@euaaaio
Any hosting or server with Node.js >=14 support
Ilya Radchenko
@knownasilya
Has anyone gotten it working on cloudflare functions?
10 replies
Eduard Aksamitov
@euaaaio
Maybe it’s possible to use Logux on Vercel like express.js: https://vercel.com/guides/using-express-with-vercel
But only just for dev, tests or fun 😅
Ilya Radchenko
@knownasilya
I'm working on a side project so that fits lol. Though wanted to do it in cloudflare, but vercel might be fine for now.
Ilya Radchenko
@knownasilya
Should server.type('...' be able to match on a pattern? server.type('room/:id/END_MOVE'?
Ilya Radchenko
@knownasilya
Seems like no. This would be a nice way to limit actions to a channel and not need to pass an id in the payload.
Andrey Sitnik
@ai
@knownasilya why do you want to avoid passing ID in payload?
Ilya Radchenko
@knownasilya
@ai it's mainly to group types to rooms, like room/ENTERED, which works fine. But if I have a channel room/:id it breaks down
I can't do a type room/:id/ENTERED
6 replies
Ilya Radchenko
@knownasilya
Has anyone deployed on google cloud run? It's docker based but also works for just plain node apps. Says it supports WS, but not sure.
8 replies
Ilya Radchenko
@knownasilya
Where else did you guys deploy a docker image that it worked?
1 reply
Ilya Radchenko
@knownasilya
Looks like I needed host 0.0.0.0 instead of 127.0.0.1
I didn't notice the comment here: https://logux.io/recipes/deployment/
Ilya Radchenko
@knownasilya
I would love to see some state chart features built in, like you can only fire these events if you are in this channel. Other events are ignored (logged).
Felix Green
@felixakiragreen

hey! I'm a frontend dev, so I apologize if this is a stupid question. I'm wondering if I can use Logux without creating a backend for it? (personal project)

I have a frontend & a postgres db (supabase), and it supports WS connections. But I've gotten this far without having to make a backend... so I was wondering if maybe there was a way to use/wrap the proxy server on the frontend so I wouldn't need a whole separate thing.

3 replies
lunayap
@lunayap
Hi, I am not sure if this question has been asked before or not, but, is it possible to hook a Flutter app to logux server? Is it hard to implement? thank you
1 reply
how about React Native. has it been done before?
1 reply
Kasey
@kculmback
Hello, we are evaluating Logux for a new project that will need real time collaboration. Our application will be interfacing with microservice architecture, so the data that we are syncing across clients will be coming from multiple services/databases and potentially third party APIs. Data will also need to be persisted to these various services. Is this a use case that Logux would work for? Is there any examples or resources on how best to handle this with Logux (I have not noticed any in the docs)?
8 replies
OfficeDroneV2
@OfficeDroneV2

Any examples on logux/redux? Trying logux out with a counter app. I have two clients and for some reason one of the clients doesn't always update its state when reconnecting from offline mode. For example, when I disconnect both clients from internet and I decrement twice on client A and increment 3 times on client B, then when I reconnect, only one of the clients update correctly while the other one doesn't update at all. Changes from both clients do get applied at server.

Looking at ws traffic I can see both clients send actions done while it was offline to the server, and the server responds with "logux/processed" to them, but then it only replicates those actions to Client A and not Client B..

18 replies
John
@Jo86384449_twitter
Hi, I'm experimenting with the new addSyncMap() which is a really great addition to handle sync-maps! All works fine but I noticed that finished actions like tasks/changed are send to clients that should not receive them. Here https://github.com/logux/server/blob/main/add-sync-map/index.js#L14 it seems that only the sending client is excluded by default so that they are send to all clients or channel subscribers? How can we control who receives these actions?
7 replies
yinz
@uinz

Hi everyone, I have a question about CRDT.

Suppose I have an Array<string> field like [1,2,3]

User A wants to insert 'a' after 1

User B wants to insert 'b' after 2

The desired final result should be [1, 'a', 2, 'b', 3]

Can the above behavior be done with the changeSyncMap API?

//A
changeSyncMap(store, { arr: [1, 'a', 2, 3 ] })

// B
changeSyncMap(store, { arr: [1, 2, 'b' , 3 ] })
3 replies
As far as I know, notion does not use a CRDT to handle conflicts though.
But it provides a set of listBefore listAfter listRemove operators to handle array behavior