class Openfoodfacts::NumberOfIngredients
Constants
- LOCALE_PATHS
TODO: Add more locales
Public Class Methods
all(locale: DEFAULT_LOCALE, domain: DEFAULT_DOMAIN)
click to toggle source
Get last edit dates
# File lib/openfoodfacts/number_of_ingredients.rb, line 18 def all(locale: DEFAULT_LOCALE, domain: DEFAULT_DOMAIN) if path = LOCALE_PATHS[locale] Product.tags_from_page(self, "https://#{locale}.#{domain}/#{path}") end end
Public Instance Methods
products(page: -1)
click to toggle source
Get products with last edit date
# File lib/openfoodfacts/number_of_ingredients.rb, line 28 def products(page: -1) Product.from_website_page(url, page: page, products_count: products_count) if url end