Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

204
Vistas
Rails 7 failing to import yarn package (https://github.com/keisto/vanilla-rangeslider)

This is a non-jQuery version of IonRangeSlider (https://github.com/IonDen/ion.rangeSlider):

https://github.com/keisto/vanilla-rangeslider

I have used this before by trying to stick to pure JS and avoid adding another layer with JQ.

I installed this via yarn and it's in my node_modules folder.

I added this to my app/javascript/application.js file:

import IonRangeSlider from 'vanilla-rangeslider/js/rangeslider'

after also trying just:

import IonRangeSlider from 'vanilla-rangeslider'

In my compiled JS file in dev all it has is this:

  // ../../node_modules/vanilla-rangeslider/js/rangeslider.js
  var require_rangeslider = __commonJS({
    "../../node_modules/vanilla-rangeslider/js/rangeslider.js"() {
    }
  });

and if I try and initialize a slider all I get is:

Uncaught ReferenceError: ionRangeSlider is not defined

Any ideas here as to what I am missing? I have added some other yarn based JS package with no issues.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

The range slider has no exported functions, meaning you won't be able to import anything from it.

The only way to use its functions would be to add it in a script tag unfortunately.

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda