Comments (6)
Btw, this should be better than unsafe
meta { charset = "utf-8" }
however I also added charset
parameter to the builder function as well
from kotlinx.html.
UPDATE. This was stupid, I've forgot +
. I don't know where I've found this coode construct.
Original comment:
Also, this code
head {
unsafe {
raw("<meta charset=\"UTF-8\" />")
}
title("$titleText — Admin")
}
executes to
<!DOCTYPE html>
<html>
<head>
<title>Crud index — Admin</title>
</head>
</html>
This is very sad that 'type-safe' builder just throws some code away.
from kotlinx.html.
Is it DOM builder or stream? JS or JVM?
from kotlinx.html.
It's ApplicationCall#respondHtml
extension in Ktor. It uses writer.appendHTML().html(builder)
— looks like stream for me. JVM.
from kotlinx.html.
I can't reproduce this. I've just added two tests and both works well. Are you sure that it hasn't been removed by some other tool? (for example, because of tag close for meta that doesn't conform to the specification)
from kotlinx.html.
Can't reproduce this? It was edited two days ago, that was my fault...
from kotlinx.html.
Related Issues (20)
- Escaping attribute value characters break Unicode codes
- HTML5 <u> tag is missing
- Can't Download kotlinx-html-jvm from https://maven.pkg.jetbrains.space HOT 3
- Please adopt html to kotlinx.html Intellij plugin HOT 1
- Improve the documentation on custom tags
- Cannot put a div inside a th
- SAXParseException when trying to add an unclosed, raw `<link>` tag into a `head { ... }` block HOT 4
- Please make the streaming consumer easier to work with HOT 2
- htmlx
- Missing release(s), e.g. 0.11 HOT 2
- Adjust readme file to replace kotlin-js with wasm
- Add all aria attributes
- @Preview plugin for Intellij [feature]
- Rename TagConsumer.finalize()
- `attributes["hx-on::after-request"]` does not preserve double colon HOT 3
- Support path tag
- Attribute group declaration not working correctly
- Support SVG tag attributes
- TR shouldn't use TBODY as a receiver
- TBODY should be a FlowContent
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kotlinx.html.