opening-hours / opening_hours.js

Library to parse and process the opening_hours tag from OpenStreetMap data
https://openingh.ypid.de/evaluation_tool/
224 stars 121 forks source link

[Suggestion] Make SH and PH evaluation optional #463

Open naerymdan opened 7 months ago

naerymdan commented 7 months ago

I have an external set of opening hours that might or might not specify PH/SH. I do not have data for the country in question. I'd rather be able to still get general information form this library than the full stop error "no holiday definition".

Could we have something like:

new opening_hours(
  openingHours,  
  {
    lat: 41.328937, 
    lon: 19.818096,
    address: {
      country_code: "AL",
      state: 'N/A' 
    },
    {
      skip_ph: true,
      skip_sh: true 
    }
  }
);