GithubHelp home page GithubHelp logo

Comments (6)

protyposis avatar protyposis commented on July 17, 2024 2

3.0.0 released. UI type definitions have been fixed, player type definitions have been removed from the UI package. They can now be found in bitmovin-player@8.

from bitmovin-player-ui.

protyposis avatar protyposis commented on July 17, 2024 1

Thanks! Now the namespace works, however it would be better to be able to do import { SourceConfig } from 'bitmovin-player-ui'; I think.

Yes that would be much nicer and will be fixed when we move the definitions from the UI to the player package.

For the second problem, can you please open a new issue with instructions to reproduce?

from bitmovin-player-ui.

protyposis avatar protyposis commented on July 17, 2024

Thanks for reporting! You can work around the issue by including the definitions at the top of your entry point file (path to node_modules needs to be adjusted depending on where the file is placed):

/// <reference path="./node_modules/bitmovin-player-ui/src/ts/player.d.ts" />

from bitmovin-player-ui.

MichalLytek avatar MichalLytek commented on July 17, 2024

Thanks! Now the namespace works, however it would be better to be able to do import { SourceConfig } from 'bitmovin-player-ui'; I think.

The only problem is that now the webpack loader fails with this error:

D:/Praca/Projekty/oke/solocoo web/node_modules/bitmovin-player-ui/src/ts/player.d.ts
(678,7):
Property 'value' of type 'string | undefined' is not assignable to string index type 'string'..

image

from bitmovin-player-ui.

MichalLytek avatar MichalLytek commented on July 17, 2024

@protyposis
As I reported, the main.d.ts file is invalid, in newest version it even don't have the export {} statement so TS throw error File '(...)/node_modules/bitmovin-player-ui/dist/js/framework/main.d.ts' is not a module. when I import bitmovin-player-ui.

I see that in dist folder of bitmovin-player-ui package downloaded from npm there are many modules definition files, like uimanager.d.ts. I would need access to the types defined there, to make bitmovinPlayerUI.UIManager.Factory.buildDefaultUI(...) work.

What setup of compliation do you use that it throws away module.exports = playerui;? Typescript compiler should easily emit correct type definition from main.ts file 😕

from bitmovin-player-ui.

protyposis avatar protyposis commented on July 17, 2024

Fixed in develop / v3.

from bitmovin-player-ui.

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.