Giter Club home page Giter Club logo

Comments (7)

andris9 avatar andris9 commented on August 19, 2024

Currently not. node-iconv handles transliteration and has a broader support for different charsets. But in the future, when iconv-lite catches up, then yes. Right now, iconv-lite is just a fallback for the systems where node-iconv has compiling issues and node-iconv is preferred.

from encoding.

rattrayalex avatar rattrayalex commented on August 19, 2024

Perhaps time to take another look at this?

from encoding.

andris9 avatar andris9 commented on August 19, 2024

node-iconv is not a required dependency anymore and iconv-lite is used by default. node-iconv is only used if it is installed separately.

from encoding.

rattrayalex avatar rattrayalex commented on August 19, 2024

Ah, gotcha. Browserify still breaks when building encoding because it detects the iconv dep, but this can be fixed by the user by passing iconv to Browserify's ignore. So probably not worth fixing here.

from encoding.

rattrayalex avatar rattrayalex commented on August 19, 2024

Though, I believe the fix would be as easy as:

try {
    var iconv_package = 'iconv';  // this is to fool browserify so it doesn't try (in vain) to install it. 
    Iconv = require(iconv_package).Iconv;
} catch (E) {
    // node-iconv not present
}

Would be happy to submit a PR if you like.

from encoding.

andris9 avatar andris9 commented on August 19, 2024

I don't really care about browserify compatibility but haven't got anything against it, so if you'd create a PR that doesn't break anything existing and works with browserify I'd pull it.

from encoding.

rattrayalex avatar rattrayalex commented on August 19, 2024

Great, submitted. Let me know if that's okay

from encoding.

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.