Skip to content

Instantly share code, notes, and snippets.

@dgloriaweb
Last active July 22, 2018 10:58
Show Gist options
  • Save dgloriaweb/07dfd3a3fc3b2752d2e92695998ddd9f to your computer and use it in GitHub Desktop.
Save dgloriaweb/07dfd3a3fc3b2752d2e92695998ddd9f to your computer and use it in GitHub Desktop.
Javascript Demo// source http://jsbin.com/murajar
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Javascript Demo</title>
<link rel="stylesheet" type="text/css" href="css.css" />
<script type="text/javascript" src="jsC.js"></script>
</head>
<body>
<script id="jsbin-javascript">
function Shape(shapeName)
{
this.shapeName=shapeName;
Shape.Count =++Shape.Count||1;
Shape.showCount= function(){
return Shape.Count;
}
}
var shape1 = new Shape("circle");
var shape2 = new Shape("line");
var shape3 = new Shape("triangle");
var shape4 = new Shape("askdlfl");
document.write(Shape.showCount());
</script>
<script id="jsbin-source-javascript" type="text/javascript">function Shape(shapeName)
{
this.shapeName=shapeName;
Shape.Count =++Shape.Count||1;
Shape.showCount= function(){
return Shape.Count;
}
}
var shape1 = new Shape("circle");
var shape2 = new Shape("line");
var shape3 = new Shape("triangle");
var shape4 = new Shape("askdlfl");
document.write(Shape.showCount());
</script></body>
</html>
function Shape(shapeName)
{
this.shapeName=shapeName;
Shape.Count =++Shape.Count||1;
Shape.showCount= function(){
return Shape.Count;
}
}
var shape1 = new Shape("circle");
var shape2 = new Shape("line");
var shape3 = new Shape("triangle");
var shape4 = new Shape("askdlfl");
document.write(Shape.showCount());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment