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: Implement Search API for cozy-dataproxy-api #1279

Merged
merged 3 commits into from
Jan 17, 2025

Conversation

Ldoppea
Copy link
Member

@Ldoppea Ldoppea commented Jan 13, 2025

In cozy/cozy-libs#2697 we enabled cozy-apps to use the Flagship app as a DataProxy provider

This PR is responsible to implement DataProxy features in the Flagship app and to declare that it those features are available

@Ldoppea Ldoppea marked this pull request as ready for review January 16, 2025 10:37
@Ldoppea Ldoppea force-pushed the feat/trigger_replication_on_appstate_and_realtime branch from f3aeba5 to f50d62d Compare January 16, 2025 10:40
@Ldoppea Ldoppea force-pushed the feat/trigger_replication_on_appstate_and_realtime branch from f50d62d to 11582fc Compare January 16, 2025 10:54
@Ldoppea Ldoppea force-pushed the feat/search branch 3 times, most recently from 7a324ba to 1322de5 Compare January 16, 2025 11:38
package.json Outdated
@@ -70,6 +72,7 @@
"cozy-realtime": "^5.6.2",
"date-fns": "2.29.3",
"events": "^3.3.0",
"flexsearch": "^0.7.43",
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think flexsearch and comlink are necessary here? There are both dependencies from cozy-dataproxy-lib

Copy link
Member Author

Choose a reason for hiding this comment

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

Nice catch, I don't remember why I added them, fixed here

@paultranvan
Copy link
Contributor

paultranvan commented Jan 16, 2025

Love how simple this looks 😄

"cozy-client": "^52.0.0",
"cozy-clisk": "^0.38.1",
"cozy-dataproxy-lib": "^2.3.0",
Copy link
Contributor

Choose a reason for hiding this comment

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

It should be 2.4.0 I assume? To get cozy/cozy-libs#2697

Copy link
Member Author

Choose a reason for hiding this comment

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

It is not needed, 2.4.0 only impacts the DataProxyProvider that is hosted in web cozy-apps.

Copy link
Contributor

Choose a reason for hiding this comment

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

Right, my bad

@Ldoppea Ldoppea force-pushed the feat/trigger_replication_on_appstate_and_realtime branch from 11582fc to 77c1030 Compare January 17, 2025 11:33
Base automatically changed from feat/trigger_replication_on_appstate_and_realtime to feat/meta_offline January 17, 2025 11:44
For some reasons, the ReactNative API fails to resolve
`cozy-dataproxy-lib/api` path so we must use `/dist` version instead

On the opposite, Jest will fail to resolve the `/dist` version so we
cannot mock cozy-dataproxy-lib

To fix this, we wrap the imports in a local file so we can mock this
local file in Jest
@Ldoppea Ldoppea merged commit 341150d into feat/meta_offline Jan 17, 2025
1 check passed
@Ldoppea Ldoppea deleted the feat/search branch January 17, 2025 13:54
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.

3 participants