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

URL helper for the product page #952

Closed
teolemon opened this issue Jul 16, 2024 · 2 comments
Closed

URL helper for the product page #952

teolemon opened this issue Jul 16, 2024 · 2 comments
Labels

Comments

@teolemon
Copy link
Member

teolemon commented Jul 16, 2024

From a developer on the slack:

Jonah
Does the Dart / Flutter Sdk actually have a function to open the OFF product page directly or do I have to create the link myself?
1 reply

Edouard Marquez
  3 hours ago
No there is no such method, but it’s really simple to create:
https://world.openfoodfacts.org/product/7622210449283

Note: this could help for OdBL compliance, or for sharing a link to the product.

@monsieurtanuki
Copy link
Contributor

Closed as already available as OpenFoodAPIClient.getProductUri:

static Uri getProductUri(
    final String barcode, {
    final OpenFoodFactsLanguage? language,
    final OpenFoodFactsCountry? country,
    final UriProductHelper uriHelper = uriHelperFoodProd,
    required final bool replaceSubdomain,
  })

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

No branches or pull requests

2 participants