How to scale my canvas in reason, with the zoom scale?
<p>I am working on a multiple web game using JavaScript. My canvas is currently set to the width and the height of my screen. </p>

<pre><code>html
&lt;canvas id = "canvas"&gt;&lt;/canvas&gt;

javascript
var c=document.getElementById("canvas");
var ctx = c.getContext("2d");
//Making canvas scale;
c.width = window.innerWidth;
c.height = window.innerHeight;

    function resize(){
 //Add some code
   }
</code></pre>

<p>My problem is, I do not want my players to zoom out, well not by default. It will make the game look bad and give the players an edge over everyone else. So I need to add some code to go into the resize method, that regardless of scale, the canvas will not be zoomed out. If the end result is something blurry at 300%+ that is fine.</p>

<p>IMPORTANT: the resize function cannot remove or reset the canvas back to default.</p>