Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

314
Visualizações
Uncaught TypeError: Cannot read properties of null (reading 'setAttribute')

My script is working perfectly only with html, but when I export to wordpress it doesn't work and this appears I would like to know some way to request it, I'm a beginner in javascript, but I'm trying to apply the writing effect but it doesn't work:

<span class="js-typedjs"
                          data-hs-typed-options='{
                            "strings": ["de você.", "da sua família."],
                            "typeSpeed": 90,
                            "loop": true,
                            "backSpeed": 30,
                            "backDelay": 2500
                          }'></span>

enter image description here

This one doesn't work either:

<script>
    
      (function() {
        // INITIALIZATION OF MEGA MENU
        // =======================================================
        const megaMenu = new HSMegaMenu('.js-mega-menu', {
          desktop: {
            position: 'left'
          }
        });

        // INITIALIZATION OF SHOW ANIMATIONS
        // =======================================================
        new HSShowAnimation('.js-animation-link')


        // INITIALIZATION OF BOOTSTRAP VALIDATION
        // =======================================================
        HSBsValidation.init('.js-validate', {
          onSubmit: data => {
            data.event.preventDefault()
            alert('Submited')
          }
        })


        // INITIALIZATION OF GO TO
        // =======================================================
        new HSGoTo('.js-go-to')


        // INITIALIZATION OF NAV SCROLLER
        // =======================================================
        new HsNavScroller('.js-nav-scroller')


        // INITIALIZATION OF TEXT ANIMATION (TYPING)
        // =======================================================
        const typed = HSCore.components.HSTyped.init('.js-typedjs')
      })()
    </script>
about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

If you don't use the animation effect, you can remove this part or the "js-animation-link" class from your HTML:

  // INITIALIZATION OF SHOW ANIMATIONS
    // =======================================================
    new HSShowAnimation('.js-animation-link')

If you do use the CSS class "js-animation-link", you need to add the element as "targetSelector" in the options, for example:

<a class="js-animation-link" href="javascript:;" role="button"
   data-hs-show-animation-options='{
       "targetSelector": "#signupModalFormLogin",
       "groupName": "idForm"
   }'>Log in here</a>

Or, in this documentation they use data-target: https://htmlstream.com/preview/front-v2.9.2/documentation/hs-libraries/show-animation.html#how-to-use

  <a class="js-animation-link btn btn-sm btn-outline-secondary btn-sm-wide active" href="javascript:;"
 data-target="#firstContent"
 data-link-group="groups"
 data-animation-in="slideInUp">First content</a> 
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda