Non-Compromises
The nonCompromise array allows you to define properties that the search must adhere to
The nonCompromise
array defines strict requirements that venues must meet to appear in your results. Often preferences can be compromised, but for times when there's a deal-breaker, define the non-compromise preference.
Basic usage
You can have multiple non-compromise filters, but each one narrows down your results considerably, so use them with caution.
How non-compromise works
Non-compromise preferences are applied as strict filters:
- Must-have requirements: Venues that don't meet these criteria are excluded
- Result reduction: Using many non-compromise filters can significantly reduce results
- Quality guarantee: Results are guaranteed to meet specified requirements, but the user should still do their own due diligence about a venue to make sure it meets their needs.
Non-compromise filters
genre
Venues must be of a specific genre.
catersFilters
Venues must cater to a specific types.
establishmentFilters
Venues offer a specific type of service.
openingConditions
Venues must be open no or at a specific time.
Real-world example
When to use non-compromise
Use non-compromise for:
- Safety requirements: Dietary allergies, accessibility needs
- Legal requirements: Age restrictions, licensing requirements
- Functional requirements: Must be open, etc
- User deal-breakers: Features users absolutely cannot compromise on
Use regular preferences for:
- Nice-to-have features: Preferred atmosphere, cuisine type
- Flexible requirements: Distance preferences, price ranges
- User preferences: Chain vs. independent, casual vs. formal
Best practice
- Use sparingly: Each non-compromise filter reduces available venues
- Prioritize essentials: Focus on must-have requirements only
- Consider user experience: Don't eliminate all options with overly strict filters