let data = {
title: 'Тайтл | Регистрация',
message: {
header: 'Ошибка',
text: 'Вы забыли разгадать капчу',
status: 'danger'
}
};
var classes = ['a', 'b', 'c'];
var $columns = $('<div/>');
classes.forEach(function(cls) {
var $column = $('<select/>').addClass(cls);
$columns.append($column);
$column.selectize();
});
$('#containter').append($columns);
var classes = ['a', 'b', 'c'];
var $wrapper = $('<div/>');
classes.forEach(function(cls) {
var $column = $('<select/>').addClass(cls);
$wrapper.append($column);
});
$('#containter').append($wrapper);
$wrapper.children().selectize();
Должно сработать. if(platform.product === 'iPad') {
document.body.classList.add('is-tablet');
}
@media(min-width: 1280px) {
.is-tablet {
// код CSS
}
}
var http = require('http'),
fs = require('fs');
http.createServer(function(req, res) {
if(req.url == "/") {
fs.readFile("index.html", {encoding: 'utf8'}, function(err, content) {
if(err) throw err;
res.end(content);
});
} else if(req.url.includes('client')) {
fs.readFile("client.js", {encoding: 'utf8'}, function(err, content) {
if(err) throw err;
res.end(content);
});
} else {
res.end("Bad request");
}
}).listen(3000);
class Animal {
private name: string;
constructor(theName: string) { this.name = theName; }
}
new Animal("Cat").name; // Error: 'name' is private;