* How to both export html and show the code?
@ 2020-05-28 4:15 George Mauer
0 siblings, 0 replies; only message in thread
From: George Mauer @ 2020-05-28 4:15 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1138 bytes --]
I would like to both render html and show a source block for the rendered
html (I am aware of ob-browser, but I want this to be dynamic html content,
not an image)
I would have thought the following would work, but noweb returns an empty
string
Well, this is solvable with css is it not?
#+name: challenge-1-solution
#+begin_export html
<article id="gradient-colors">
<div></div>
<style>
#gradient-colors div {
width: 400px;
height: 200px;
animation: gradient 5s infinite linear;
}
@keyframes gradient {
0% {
background-color: hsl(0, 100%, 50%);
}
25% {
background-color: hsl(90, 100%, 50%);
}
50% {
background-color: hsl(180, 100%, 50%);
}
75% {
background-color: hsl(270, 100%, 50%);
}
100% {
background-color: hsl(360, 100%, 50%);
}
}
</style>
</article>
#+end_export
#+begin_src html :eval no :exports code :noweb yes
<<challenge-1-solution>>
#+end_src
[-- Attachment #2: Type: text/html, Size: 1814 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-05-28 4:16 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-05-28 4:15 How to both export html and show the code? George Mauer
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).