Subba Rao G
12/30/2021, 5:11 AMy9san9
12/30/2021, 4:34 PMBig Chungus
12/30/2021, 6:20 PMSubba Rao G
12/30/2021, 9:01 PMSubba Rao G
01/03/2022, 9:43 PM> Task :jsGenerateExternals
Exception in thread "main" java.lang.StackOverflowError
at java.base/java.util.HashMap.hash(HashMap.java:339)
at java.base/java.util.LinkedHashMap.getOrDefault(LinkedHashMap.java:452)
at org.jetbrains.dukat.tsLowerings.TypeSpecifierLowering.spec(TypeAliasContext.kt:20)
at org.jetbrains.dukat.tsLowerings.TypeSpecifierLowering.lowerParameterValue(TypeAliasContext.kt:39)
at org.jetbrains.dukat.tsLowerings.DeclarationLowering$DefaultImpls.lowerUnionTypeDeclaration(DeclarationLowering.kt:132)
at org.jetbrains.dukat.tsLowerings.TypeSpecifierLowering.lowerUnionTypeDeclaration(TypeAliasContext.kt:15)
Nikola Milovic
01/04/2022, 11:27 AM<motion.div
animate= {{x: [50, 0], opacity: [0,1]}} // X will go from 50% to 0% and opacity from 0% to 100%
I tried to translate the animate property with dynamics
val animate = js("{}")
animate.x = listOf(50, 0)
animate.opacity = listOf(0, 1)
When it gets converted to JS, the lists are ArrayLists instead of what I'd expect to be a List and even adding .toList
results in the same transformation.
For some reason this doesn't work, and I have to use
animate.x = js("[50,0]")
animate.opacity = js("[0,1]")
For it to work as expected , which doesn't allow me to pass parameters as js()
only accepts string literals
1.5.31
KotlinTim Ortel
01/05/2022, 11:49 AMTim Ortel
01/05/2022, 4:16 PMKios
01/05/2022, 5:10 PMxxfast
01/06/2022, 10:07 PMFlow<State>
with a reach-hookGabriel Duncan
01/08/2022, 3:39 PMSubba Rao G
01/08/2022, 6:49 PMMichael Evans
01/09/2022, 5:42 PMjanvladimirmostert
01/09/2022, 8:17 PM@JsName("blah2")
suspend fun blah2() {
should I GlobalScope its insides or is there a cleaner way?
@JsName("blah2")
fun blah2() {
GlobalScope.launch {
flow.collect {
println(it)
}
}
}
Piotr Krzemiński
01/10/2022, 2:00 PMkotlin-csstype
, kotlin-css
and I think sometimes I need to use dynamic JS object. Are there any plans to unify it? 😅 it's especially inconvenient when both kotlin-csstype
and kotlin-css
has the same names of functions and need to be imported in the same file, e.g. when using React and Styled Components in the same componentGabriel Duncan
01/10/2022, 4:44 PMcolors
thing. is there a way i can pin a version of a library that is included by a dependency indirectly through npm? i know in jvm lang you can force pin a transitive dependency but not sure that works for npmRobert Munro
01/10/2022, 7:04 PMCould not determine the dependencies of task ':kotlinNodeJsSetup'.
> Could not resolve all files for configuration ':detachedConfiguration1'.
> Could not download node-14.17.0-darwin-x64.tar.gz (org.nodejs:node:14.17.0): No cached version available for offline mode
Possible solution:
- Disable offline mode and rerun the build
found this bug which looks similar. I am on kotlin 1.5.31 - is the only sloution to upgrade to kotlin 1.6? maybe it not a problem but just might be some work.
https://youtrack.jetbrains.com/issue/KT-49109Richard Chao
01/12/2022, 10:35 PMbuild/js
output via ./gradlew build
. i have tried to link the build/js
folder via yarn link
and i also tried to npm install it by adding the absolute path to the package.json of the js project. However i am getting the error Error: Can't resolve '@js-joda/core' in home/node/jsProject/node_modules/kotlinProject/kotlin
. I think i am not installing the dependencies correctly in the build/js
folder when i used ./gradlew build
Alexander Stoppel
01/13/2022, 6:56 AMspand
01/13/2022, 1:43 PMKT-34014 Gradle, JS: Ability to persist / reuse yarn.lock
?Nikolai Sviridov
01/13/2022, 3:46 PMhistoryApiFallback: true
in webpack config. My webpack.config.d/03.devServer.js looks like this (copy from previous versions of full-stack-web-jetbrains-night-sample (current one doesn't work )):
// wrap is useful, because declaring variables in module can be already declared
// module creates own lexical environment
;(function (config) {
const shouldRunServer = config.mode !== "production"
const serverTaskName = ":server:devServer"
const serverUrl = '<http://localhost:8081>'
const path = require('path')
if (shouldRunServer) {
console.log("Running " + serverTaskName + " in background...")
// __dirname = $ROOT/build/js/packages/$PACKAGE_NAME
// rootProject = $ROOT
const rootProject = path.resolve(__dirname, '../../../../')
const child = require('child_process').exec(
"." + path.sep + "gradlew " + serverTaskName,
{
"cwd": rootProject
},
(err, stdout, stderr) => {
if (err) {
console.log("Cannot run " + serverTaskName + " server: " + err);
}
}
)
let isBackendRun = false
config.devServer = config.devServer || {}
config.devServer.onBeforeSetupMiddleware = function (server) {
if (isBackendRun) return
isBackendRun = true
const originalClose = server.middleware.close;
server.middleware.close = function () {
child.kill('SIGINT');
originalClose(arguments)
}
}
config.devServer.proxy = {
'/': {
target: serverUrl,
secure: false,
bypass: function (req, res, proxyOptions) {
if (req.headers.accept.indexOf('.js') !== -1) {
return req.headers.accept;
}
}
}
}
}
config.devServer = {
...config.devServer,
historyApiFallback: true,
}
// config.devServer["historyApiFallback"] = true // doesn't work too
})(config);
I need it for react routing to be able to work with reloading and using external url. Am I missing something and it should be in another place or smth else?martmists
01/14/2022, 3:37 AMdependencies {
implementation(compose.web.core)
implementation(compose.runtime)
implementation("io.ktor:ktor-client-core:1.6.7")
// From <https://github.com/gzoritchak/kotlin-js-sass>
implementation(npm(projectDir.resolve("src/main/sass")))
implementation(devNpm("node-sass", "^4.12.0"))
implementation(devNpm("sass-loader", "^7.1.0"))
implementation(devNpm("css-loader", "^4.2.0"))
implementation(devNpm("style-loader","^1.2.0"))
implementation(project(":common"))
}
Piotr Krzemiński
01/14/2022, 7:17 AMAkash
01/14/2022, 9:20 AMGabriel Duncan
01/14/2022, 12:40 PMhfhbd
01/15/2022, 3:55 PMwebpack.config.d
containing the config.js files, but I still get his error:
Execution failed for task ':web:jsBrowserProductionWebpack'.
> Module not found: Error: Can't resolve 'path' in '/Users/philipwedemann/GitHub/ComposeTodo/build/js/node_modules/sql.js/dist'
Rohan Maity
01/16/2022, 9:30 AM@material/textfield
in my project
https://www.npmjs.com/package/@material/textfield
I have added the following dependency as
implementation(npm("@material/textfield", "13.0.0")
But after that, I am not able to understand, how to create the an adapter file for this
Its not a simple function
Does anyone here have similar problem or used npm dependency in kotlin web ?Robert Jaros
01/16/2022, 11:08 AMRohan Maity
01/16/2022, 12:52 PMimplementation(enforcedPlatform("org.jetbrains.kotlin-wrappers:kotlin-wrappers-bom:${kotlinWrappersVersion}"))
I am not able to see enforcedPlatform
in build.gradle.kts
Do I have to use any other plugin as well ?
cc @turansky This is from the kotlin-wrappers librarymartmists
01/16/2022, 10:20 PM2022-01-16T23:07:25.134+0100 [ERROR] [org.gradle.api.Task] e: java.lang.ClassCastException: class org.jetbrains.kotlin.ir.expressions.impl.IrGetValueImpl cannot be cast to class org.jetbrains.kotlin.ir.expressions.IrVararg (org.jetbrains.kotlin.ir.expressions.impl.IrGetValueImpl and org.jetbrains.kotlin.ir.expressions.IrVararg are in unnamed module of loader 'app')
martmists
01/16/2022, 10:20 PM2022-01-16T23:07:25.134+0100 [ERROR] [org.gradle.api.Task] e: java.lang.ClassCastException: class org.jetbrains.kotlin.ir.expressions.impl.IrGetValueImpl cannot be cast to class org.jetbrains.kotlin.ir.expressions.IrVararg (org.jetbrains.kotlin.ir.expressions.impl.IrGetValueImpl and org.jetbrains.kotlin.ir.expressions.IrVararg are in unnamed module of loader 'app')
p.plugins.autoloader.loadLanguages(arrayOf("abap", "abnf", "actionscript", "ada", "agda", "al", "antlr4", "apacheconf", "apex", "apl", "applescript", "aql", "arduino", "arff", "asciidoc", "asm6502", "asmatmel", "aspnet", "autohotkey", "autoit", "avisynth", "avro-idl", "bash", "basic", "batch", "bbcode", "bicep", "birb", "bison", "bnf", "brainfuck", "brightscript", "bro", "bsl", "c", "cfscript", "chaiscript", "cil", "clike", "clojure", "cmake", "cobol", "coffeescript", "concurnas", "coq", "core", "cpp", "crystal", "csharp", "cshtml", "csp", "css", "css-extras", "csv", "cypher", "d", "dart", "dataweave", "dax", "dhall", "diff", "django", "dns-zone-file", "docker", "dot", "ebnf", "editorconfig", "eiffel", "ejs", "elixir", "elm", "erb", "erlang", "etlua", "excel-formula", "factor", "false", "firestore-security-rules", "flow", "fortran", "fsharp", "ftl", "gap", "gcode", "gdscript", "gedcom", "gherkin", "git", "glsl", "gml", "gn", "go", "go-module", "graphql", "groovy", "haml", "handlebars", "haskell", "haxe", "hcl", "hlsl", "hoon", "hpkp", "hsts", "http", "ichigojam", "icon", "icu-message-format", "idris", "iecst", "ignore", "inform7", "ini", "io", "j", "java", "javadoc", "javadoclike", "javascript", "javastacktrace", "jexl", "jolie", "jq", "js-extras", "js-templates", "jsdoc", "json", "json5", "jsonp", "jsstacktrace", "jsx", "julia", "keepalived", "keyman", "kotlin", "kumir", "kusto", "latex", "latte", "less", "lilypond", "liquid", "lisp", "livescript", "llvm", "log", "lolcode", "lua", "magma", "makefile", "markdown", "markup", "markup-templating", "matlab", "maxscript", "mel", "mermaid", "mizar", "mongodb", "monkey", "moonscript", "n1ql", "n4js", "nand2tetris-hdl", "naniscript", "nasm", "neon", "nevod", "nginx", "nim", "nix", "nsis", "objectivec", "ocaml", "opencl", "openqasm", "oz", "parigp", "parser", "pascal", "pascaligo", "pcaxis", "peoplecode", "perl", "php", "php-extras", "phpdoc", "plsql", "powerquery", "powershell", "processing", "prolog", "promql", "properties", "protobuf", "psl", "pug", "puppet", "pure", "purebasic", "purescript", "python", "q", "qml", "qore", "qsharp", "r", "racket", "reason", "regex", "rego", "renpy", "rest", "rip", "roboconf", "robotframework", "ruby", "rust", "sas", "sass", "scala", "scheme", "scss", "shell-session", "smali", "smalltalk", "smarty", "sml", "solidity", "solution-file", "soy", "sparql", "splunk-spl", "sqf", "sql", "squirrel", "stan", "stylus", "swift", "systemd", "t4-cs", "t4-templating", "t4-vb", "tap", "tcl", "textile", "toml", "tremor", "tsx", "tt2", "turtle", "twig", "typescript", "typoscript", "unrealscript", "uri", "v", "vala", "vbnet", "velocity", "verilog", "vhdl", "vim", "visual-basic", "warpscript", "wasm", "web-idl", "wiki", "wolfram", "wren", "xeora", "xml-doc", "xojo", "xquery", "yaml", "yang", "zig"), console::log, console::error)
rnett
01/17/2022, 3:36 AM