Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

231
Views
react-bootstrap-typeahead default styling

I am trying to use react-bootstrap-typeahead in my project. The problem is that formatting looks pretty awful. I tried running the exact same code in an online sandbox. There it looks fine.

enter image description here

At first i thought that the sandbox is applying explicit styles, but that does not seem to be the case. As far as i can tell, it is using the default styling of the typeahead competent instead of applying heavy formatting. https://codesandbox.io/s/9jq9jyzmry

I suspect that something in my app is overriding the styling used by the typeahead and leading to it being improperly rendered.

I realize it is possible to apply custom formatting to the typeahead, but that feels laborious. Is there a way to force default styling on the typeahead?

For reference, here's the code:

import React, { useState } from 'react';
import { Typeahead } from 'react-bootstrap-typeahead';

const MyPicker = () => {
  const [selected, setSelected] = useState([]);
  const handleChange = (sel) => setSelected(sel);
  return (
    <div>
      <Typeahead
        multiple
        clearButton
        id="my-typeahead"
        labelKey="fullname"
        onChange={handleChange}
        options={[
          {
            fullname: 'Apple',
          },
          {
            fullname: 'Banana',
          },
          {
            fullname: 'Peach',
          },
          {
            fullname: 'Zucchini',
          },
        ]}
        placeholder="Select options..."
        selected={selected}
      />
    </div>
  );
};

export default MyPicker;
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!