Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Jun 01 21:50

    oyvindberg on v1.0.0-beta33

    (compare)

  • Jun 01 21:49

    oyvindberg on gh-pages

    Deploy website Deploy website … (compare)

  • Jun 01 21:07

    oyvindberg on support-abstract-new-syntax

    (compare)

  • Jun 01 21:06

    oyvindberg on master

    Support `abstract new` syntax (… (compare)

  • Jun 01 20:59

    oyvindberg on support-abstract-new-syntax

    Support `abstract new` syntax (compare)

  • Jun 01 20:45

    oyvindberg on dotty-support

    better erasure for this.type fixup `val a: Null = js.native` seems… and 2 more (compare)

  • May 29 07:56

    oyvindberg on dotty-support

    fork tests (compare)

  • May 29 07:00

    oyvindberg on dotty-support

    workaround for https://github.c… (compare)

  • May 29 06:51

    oyvindberg on dotty-support

    build snapshots (compare)

  • May 25 08:16

    oyvindberg on dotty-support

    scalafmt (compare)

  • May 25 08:08

    oyvindberg on dotty-support

    bump runtime (compare)

  • May 24 23:38

    oyvindberg on master

    Update sbt-mdoc to 2.2.21 (#306… (compare)

  • May 24 23:38

    oyvindberg on master

    Update scalatest to 3.2.9 (#307… (compare)

  • May 24 23:38

    oyvindberg on master

    Update os-lib to 0.7.7 (#308) … (compare)

  • May 24 23:32

    oyvindberg on master

    Minimization: Include what `Sho… (compare)

  • May 24 23:32

    oyvindberg on minimization-bugfix

    (compare)

  • May 24 23:07

    oyvindberg on poc-laminar

    scalafmt (compare)

  • May 24 22:52

    oyvindberg on poc-laminar

    laminar poc (compare)

  • May 24 21:02

    oyvindberg on minimization-bugfix

    Minimization: Include what `Sho… (compare)

  • May 24 21:01

    oyvindberg on master

    Update sourcecode to 0.2.7 (#30… (compare)

vonchav
@voonchav_gitlab
To be honest, I don't have a concrete approach. Still in the exploration mode.
Edward A. Maxedon, Sr.
@edadma

Hi @oyvindberg, I'm getting this baffling error that i never used to get

[error] (stImport) TsHelperFile(InFile(/home/ed/dev-work/sc/v2/shuttlecontrol-admin-api/target/scala-2.13/scalajs-bundler/main/node_modules/typescript
/lib/lib.es5.d.ts),StdLibSource(InFolder(/home/ed/dev-work/sc/v2/shuttlecontrol-admin-api/target/scala-2.13/scalajs-bundler/main/node_modules/typescript
/lib),IArray(InFile(/home/ed/dev-work/sc/v2/shuttlecontrol-admin-api/target/scala-2.13/scalajs-bundler/main/node_modules/typescript/lib/lib.dom.d.ts), InFile(/home
/ed/dev-work/sc/v2/shuttlecontrol-admin-api/target/scala-2.13/scalajs-bundler/main/node_modules/typescript
/lib/lib.es6.d.ts)),TsIdentLibrarySimple(std)),IArray(TsIdentModule(None,List(std, lib.es5)))) -> Right(Parse error at 1531.47 ''>'' expected but 'new' found)

here's the text of line 1531 in lib.es5.d.ts

type ConstructorParameters<T extends abstract new (...args: any) => any> = T extends abstract new (...args: infer P) => any ? P : never;
i'm using beta32 and haven't updated any of my js dependencies, i believe. i just updated some of my Scala.js dependencies and went to Scala 2.13.6 and that's it. Hopefully, someone can help me with this: it's for my job.
Antoine Doeraene
@sherpal
I had this issue as well earlier today. For a workaround I moved to the version of the plug-in not using scala js bundler. And then it worked
Edward A. Maxedon, Sr.
@edadma
@sherpal i just resolved it by "sneakily" downgrading the version of TypeScript (to 4.2.4) by editing the package.json doing npm install in the target/scala-2.13/scalajs-bundler/main/ folder. thanks for replying
Øyvind Raddum Berg
@oyvindberg
See also workaround here ScalablyTyped/Converter#316 . I'll get it fixed soon :)
Edward A. Maxedon, Sr.
@edadma
@oyvindberg thanks, i was looking for something like the stTypescriptVersion option on the website. i'll use that now. thanks for the info.
Jason Pickens
@steinybot
Any idea what this error could be about?
[error] java.lang.RuntimeException: TsHelperFile(InFile(/codebuild/output/src791674158/src/codestar-connections.ap-southeast-2.amazonaws.com/git-http/889040691558/ap-southeast-2/aee8be3e-d20a-4d4c-ba38-5e3db37368d3/tlayen/platform/erp-shared/js/target/scala-2.12/scalajs-bundler/main/node_modules/typescript/lib/lib.es5.d.ts),StdLibSource(InFolder(/codebuild/output/src791674158/src/codestar-connections.ap-southeast-2.amazonaws.com/git-http/889040691558/ap-southeast-2/aee8be3e-d20a-4d4c-ba38-5e3db37368d3/tlayen/platform/erp-shared/js/target/scala-2.12/scalajs-bundler/main/node_modules/typescript/lib),IArray(InFile(/codebuild/output/src791674158/src/codestar-connections.ap-southeast-2.amazonaws.com/git-http/889040691558/ap-southeast-2/aee8be3e-d20a-4d4c-ba38-5e3db37368d3/tlayen/platform/erp-shared/js/target/scala-2.12/scalajs-bundler/main/node_modules/typescript/lib/lib.dom.d.ts), InFile(/codebuild/output/src791674158/src/codestar-connections.ap-southeast-2.amazonaws.com/git-http/889040691558/ap-southeast-2/aee8be3e-d20a-4d4c-ba38-5e3db37368d3/tlayen/platform/erp-shared/js/target/scala-2.12/scalajs-bundler/main/node_modules/typescript/lib/lib.es6.d.ts)),TsIdentLibrarySimple(std)),IArray(TsIdentModule(None,List(std, lib.es5)))) -> Right(Parse error at 1531.47 ''>'' expected but 'new' found)
[error]     at scala.sys.package$.error(package.scala:30)
[error]     at org.scalablytyped.converter.plugin.ScalablyTypedConverterPlugin$.$anonfun$stImportTask$7(ScalablyTypedConverterPlugin.scala:88)
[error]     at scala.Function1.$anonfun$compose$1(Function1.scala:49)
[error]     at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:62)
[error]     at sbt.std.Transform$$anon$4.work(Transform.scala:68)
[error]     at sbt.Execute.$anonfun$submit$2(Execute.scala:282)
[error]     at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:23)
[error]     at sbt.Execute.work(Execute.scala:291)
[error]     at sbt.Execute.$anonfun$submit$1(Execute.scala:282)
[error]     at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:265)
[error]     at sbt.CompletionService$$anon$2.call(CompletionService.scala:64)
[error]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error]     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error]     at java.lang.Thread.run(Thread.java:748)
It only fails on our build machine and works locally.
Øyvind Raddum Berg
@oyvindberg
@steinybot same as above, check the workaround in issue 316 linked above
Jason Pickens
@steinybot
Oh woops didn’t see that, sorry.
elkhadirzyad
@elkhadirzyad
hello mr Oyvind, could you remind me why there is no material ui v4
Øyvind Raddum Berg
@oyvindberg
@elkhadirzyad basically because it's difficult and I don't have much time. Since autumn I've been working on finalizing the general encoding and scala 3 support. The idea is that mui4 will come after scala 3
On the bright side scala 3 support feels quite close now, many demos work with the latest snapshot, though there are a few regressions I still need to work out
elkhadirzyad
@elkhadirzyad
@oyvindberg thank u, is there an opened issue about mui 4 ?
Øyvind Raddum Berg
@oyvindberg
Well yes, ScalablyTyped/Converter#208 and the one it links to
Øyvind Raddum Berg
@oyvindberg
Released a fix for the abstract new issue in 1.0.0-beta33
Jason Pickens
@steinybot
Thanks @oyvindberg! I can confirm that it fixed my issue.
elkhadirzyad
@elkhadirzyad
hello guys, do u have an idea about javascript editors written with scala 2.13
elkhadirzyad
@elkhadirzyad
image.png
hello @oyvindberg , when i try to use sbt-scalablytyped i got the error
Øyvind Raddum Berg
@oyvindberg
@elkhadirzyad are you trying to use a snapshot?
@elkhadirzyad there is a demo which uses the JavaScript editor Monaco in one of the demo repos with scala 2.13 if that's what you mean
elkhadirzyad
@elkhadirzyad
@oyvindberg yes for monaco, is there a demo in slinky version demos or japgolly version ? For sbt-scalablytyped i followed the documentation which use d3 as example and gave me the error.
Øyvind Raddum Berg
@oyvindberg
@elkhadirzyad what documentation was that? seems like some ancient stuff. Can you try the instructions at scalablytyped.org?
Robert Walker
@olofwalker
@oyvindberg Is it possible to use a local npm package with the plugin? Trying to use a Wasm module with a Typescript interface in ScalaJs, no intention to publish it.
elkhadirzyad
@elkhadirzyad
@oyvindberg , i follow the instructions https://github.com/ScalablyTyped/ScalajsReactTyped but there is no sbt-scalablytyped
Øyvind Raddum Berg
@oyvindberg
Aha thanks @elkhadirzyad those are outdated, I'll remove them. Use what is documented at scalablytyped.org
Øyvind Raddum Berg
@oyvindberg
@olofwalker i think there are ways, yes. If you use the approach without scalajs-bundler you can add it to package.json as a file. Or maybe you can add a local repository to npm/yarn
Øyvind Raddum Berg
@oyvindberg
No idea, you'll have to try
elkhadirzyad
@elkhadirzyad
@oyvindberg , i found the typins for ace project here, https://github.com/ScalablyTyped/ScalajsReactTyped/tree/master/a/ace , how can i generate a demo from it, the documentation is outdated
Øyvind Raddum Berg
@oyvindberg
Ignore that repo and read the docs and look at the demos instead please
Øyvind Raddum Berg
@oyvindberg
Then you need to state what you have tried and what doesn't work
elkhadirzyad
@elkhadirzyad
@oyvindberg , where do we usethe typings declared here https://github.com/ScalablyTyped/Distribution ?
Øyvind Raddum Berg
@oyvindberg
@elkhadirzyad You don't. You use the sbt plugin (or the command line tool) documented at scalablytyped.org
elkhadirzyad
@elkhadirzyad
ok @oyvindberg , for example if i want to convert the ace library should i use the scala.js typings of this library ? i could not find such information
Øyvind Raddum Berg
@oyvindberg
@elkhadirzyad I've written you a PM with a complaint of your behaviour over the last year or so. Warning 1/1
Robert Walker
@olofwalker
@oyvindberg Thanks, I will look into it!
Shah Saraei
@ShahOdin
:wave: is there a hello-world example of scalablyTyped being used in a cross build project? I followed the instructions on https://scalablytyped.org/docs/readme.html#getting-started but adding anything to Compile.npmDependencies gives me:
java.lang.RuntimeException: TsHelperFile ..... IArray(TsIdentModule(None,List(std, lib.es5)))) -> Right(Parse error at 1531.47 ''>'' expected but 'new' found)
I am using:
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.5.1")
addSbtPlugin("ch.epfl.scala" % "sbt-scalajs-bundler" % "0.20.0")
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.0.0")
addSbtPlugin("org.scalablytyped.converter" % "sbt-converter" % "1.0.0-beta32")
Øyvind Raddum Berg
@oyvindberg
@ShahOdin upgrade to 1.0.0-beta33 . This was a recent problem because ST (and npm) automatically picks up the newest version of typescript, and typescript version 4.3 required a change to the parser in ST
Shah Saraei
@ShahOdin
Worked like a charm. Thanks for the real-time support! :D
Shah Saraei
@ShahOdin
@oyvindberg hmmm would this be a problem with the converter plugin? https://gitter.im/scala-js/scala-js?at=60bfba3781b45810b890e0ec curious as to why such methods are generated if the user can't actually do anything with them. :/
Antoine Doeraene
@sherpal
I guess in TS this would be used as if (typeof(stuff) === "string") and I guess you can do this check in Scala (except you have to manually cast afterwards)
Øyvind Raddum Berg
@oyvindberg
answered you in the other channel @ShahOdin , but exactly what @sherpal said with other words :)
Alexis Hernandez
@AlexITC
@ShahOdin this project cross-builds to scala and sjs, and uses scalablytyped
Dan Di Spaltro
@dispalt
@oyvindberg hey so I am running into issues syncing to s3 and I think I finally discovered the problem. It doesn't occur in my CI environment that runs on aws. it's because you basically start all the uploads at once
Øyvind Raddum Berg
@oyvindberg
@dispalt aha! That makes sense, it does push everything at once. That was easiest to write, and since I haven't seen any problems with it I haven't looked at it again