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

162
Views
Selectize js on calling change method giving undefined error when using with React Final Form

This is the error message I'm getting :

Cannot read properties of undefined (reading 'change')

enter image description here

This is how I'm calling selectize change method :

this.selectize.on('change', this.onChange);

Here, onChange is a prop, which calls the onSubmit method of react-final-form, and onSubmit definition is as below :

 const onSubmit = ({ content, url }, { reset }) => { 
    if (content) {
      const action = !content.get('campaignId') ? addContent : addCampaign;

      return action(content).then(() => {
        reset();

        if (contentSelector && contentSelector.current) {
          contentSelector.current.exclude(
            content.get('id') || content.get('campaignId')
          );
          contentSelector.current.selectize.blur();
        }
      });
    }

    if (url) {
      return addExternal(url).then(reset);
    }

    return null;
  };
about 4 years ago · Santiago Gelvez
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!