Q:

Some method, for using javascript output in inline css?

I thought, would be cozy, if I can use an script output in inline css for max-height value from the current screen height, suchlike this:
I get the current screen's height with javascript:
<script type="text/javascript">
var w = window,
d = document,
e = d.documentElement,
gmodal = d.getElementsByTagName('body')[0],
ymodal = w.innerHeight||e.clientHeight||gmodal.clientHeight;</script>

But, any method, that I can use this in inline css, like:
<div style="max-height:'{ymodal}'">

A:

You can use max-height: 100vh; to get an element to be the height of the inner window height.
If you still need to insert a JavaScript variable into a css property, you are probably going to need to use element.style.*
<div id='some-id'></div>

<script type="text/javascript">
    var w = window,
        d = document,
        e = d.documentElement,
        gmodal = d.getElementsByTagName('body')[0],
        ymodal = w.innerHeight || e.clientHeight || gmodal.clientHeight;
    document.getElementById('some-id').style.maxHeight = ymodal + 'px';
</script>

Note the + 'px' and using maxHeight instead of max-height

