Giter Site home page Giter Site logo

Gauge is not defined about svg-gauge HOT 4 OPEN

naikus avatar naikus commented on May 24, 2024
Gauge is not defined

from svg-gauge.

Comments (4)

naikus avatar naikus commented on May 24, 2024 1

@moalamri svg-gauge is an es module and I've used it in my project via require("svg-gauge") and
import gauge from "svg-gauge"

from svg-gauge.

naikus avatar naikus commented on May 24, 2024

Hi @patson12 can you share a repo or some starter code?

from svg-gauge.

moalamri avatar moalamri commented on May 24, 2024

@naikus I'm guessing it is because svg-gauge is not a module therefore there's no default exporter.
I wish the codebase could be converted to ES6+ so modifications could be easier. I'm still learning JS, so I couldn't really digest the codebase to make it ES6 for easier IDE integration.

Is it possible to make it ES6+ with TS support? If so then I'm willing to make TS declaration interface for svg-gauge :)

from svg-gauge.

moalamri avatar moalamri commented on May 24, 2024

I'm sorry I didn't notice the ts declaration interface svg-gauge.d.ts

It's because I wanted to change few things, but I didn't clone the whole package (only src/index.js) that's why I was getting not a module error.

Anyways I wish if the source is more human readable πŸ˜… maybe it's only difficult for me. Since you have better experience in JS, is there a way to have one-click solution to convert between JS versions?

Thanks

from svg-gauge.

Related Issues (20)

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.