Rocky_Mountain_Vending/.pnpm-store/v10/files/f4/31ff8e36e23c00beb2bb79009a20fb432b5cd94b109c7af9e71fdfbde93272cdccb60a3b073b399a47d555b1ba74ef361b163e82cf118e92eefe7d1edd6792
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

15 lines
644 B
Text

// @flow
// "lookup" algorithm http://tools.ietf.org/html/rfc4647#section-3.4
// assumes normalized language tags, and matches in a case sensitive manner
module.exports = function lookupClosestLocale (locale/*: string | string[] | void */, available/*: { [string]: any } */)/*: ?string */ {
if (typeof locale === 'string' && available[locale]) return locale
var locales = [].concat(locale || [])
for (var l = 0, ll = locales.length; l < ll; ++l) {
var current = locales[l].split('-')
while (current.length) {
var candidate = current.join('-')
if (available[candidate]) return candidate
current.pop()
}
}
}