question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[ais-configure] The widget does not work with HTML template

See original GitHub issue

One requirement of the ais-configure widget is that the prop must be camel-case. But it doesn’t work with an HTML template since HTML is case-insensitive. The attributes are always lowercase. It does throw an error on the API side (see example).

https://discourse.algolia.com/t/camelcase-attributes-in-ais-configure/7080/3

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:9 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
Haroenvcommented, Feb 20, 2019

I’ve tried this out in html templates and string templates, and .camel is the way to go. I made a PR to the docs to mention this solution specifically (will be deployed in 3 weeks, because docs are currently in code freeze).

<ais-configure
  v-bind:hits-per-page.camel="4"
  v-bind:distinct="true"
></ais-configure>
0reactions
Haroenvcommented, May 10, 2019

I don’t understand your question @donPuerto, the code you wrote seems valid to me. Can you open a new issue with full reproduction and a clear description of the problem?

Read more comments on GitHub >

github_iconTop Results From Across the Web

camelCase attributes in <ais-configure> - Algolia Community
I solved this by wrapping the ais-configure component in a .vue single file component, it works there. I previously had it directly in...
Read more >
Algolia -> Unable to make filters work with ais-configure Widget
in my documents. However, the filter doesn't work. Actually, it filters all documents irrespective of the value of the attribute. I tried ...
Read more >
How to Set up an Algolia Instasearch App on your Strattic Site
This guide assumes you're bringing your own Algolia index, and not using Strattic's index of your site. From there, you will need three...
Read more >
instantsearch.js - npm
API is unstable. We welcome any idea and pull request. Setup. npm, browserify, webpack; <script>. Usage; Widget API; Templates.
Read more >
How To Implement Search Functionality In Your Nuxt App ...
As parameters to algoliaSearch then assign it to searchClient which we will use in our <template> to configure our Algolia search widgets. ais- ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found