Skip to content

Instantly share code, notes, and snippets.

View kamito's full-sized avatar

Shinichirow KAMITO kamito

  • Groovenauts, Inc.
  • Japan
View GitHub Profile
var http = require('http');
http.createServer(function(request, response) {
response.writeHead(200, {'Content-Type':'text/html'});
response.end('<h1>Hello! node.js</h1>');
}).listen(8081);
console.log('Server running at http://127.0.0.1:8081/');
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title>416.bz: Google Closure Library Sample</title>
<!--// common.cssを読み込む //-->
<link rel="stylesheet" type="text/css" href="google-closure-library/closure/goog/css/common.css" />
<link rel="stylesheet" type="text/css" href="google-closure-library/closure/goog/css/button.css" />
<link rel="stylesheet" type="text/css" href="google-closure-library/closure/goog/css/custombutton.css" />
</head>
<body>
/**
* app.js
*/
// オブジェクト領域を確保する
goog.provide("app");
goog.provide("app.Base");
goog.provide("app.Page");
goog.require("goog.dom"); // DOM関連ライブラリを読み込む
[amazon asin=1234567890 type=mini]
/**
* app.js
*/
// オブジェクト領域を確保する
goog.provide("app");
goog.provide("app.Base");
goog.provide("app.Page");
goog.require("goog.dom"); // DOM関連ライブラリを読み込む
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title>416.bz: Google Closure Library Sample</title>
<!--// common.cssを読み込む //-->
<link rel="stylesheet" type="text/css" href="google-closure-library/closure/goog/css/common.css" />
</head>
<body>
<h1>416.bz: Google Closure Library Sample</h1>
<div id="content"></div>
python ./google-closure-library/closure/bin/build/depswriter.py --output_file=deps.js --root_with_prefix="app ../../../app"
/**
* app.js
*/
// オブジェクト領域を確保する
goog.provide("app");
goog.provide("app.Base");
goog.provide("app.Page");
app.Base = function() {
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title>416.bz: Google Closure Library Sample</title>
<!--// common.cssを読み込む //-->
<link rel="stylesheet" type="text/css" href="google-closure-library/closure/goog/css/common.css" />
</head>
<body>
<h1>416.bz: Google Closure Library Sample</h1>
<div id="content"></div>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<title>416.bz: Google Closure Library Sample</title>
</head>
<body>
<h1>416.bz: Google Closure Library Sample</h1>
<div id="content"></div>
<div id="buttons"></div>
</body>