Git Product home page Git Product logo

Comments (4)

Siegrift avatar Siegrift commented on September 1, 2024

This is intended.

Variable linesHtml has type string | TrustedHTML so you only need casting to string.
Assignment element.innerHTML = linesHtml as string; works properly.

The reason for this is, that the casting trick through unknown requires the variable type to be exactly TrustedHTML (and it's an union in your case).

from tsec.

jrieken avatar jrieken commented on September 1, 2024

Assignment element.innerHTML = linesHtml as string; works properly.

Pretty sure that I have tried this but without success. Tho, I might have been on a wrong version of tsec - the yarn upgrade trick seems to be buggy and we are kinda desperate for #17. Folks keep getting a wrong version of tsec and aren't happy with tsec at all

from tsec.

engelsdamien avatar engelsdamien commented on September 1, 2024

I think I figured it out. The latest version of tsec seems to have lost the postinstall script that allows it to build, so even with the upgrade, it is still running old code. I've raised the issue internally and we'll work on a fix.

from tsec.

jrieken avatar jrieken commented on September 1, 2024

Oh, that explains a lot

from tsec.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.