-2
ich mit NodeJS verwenden Bootstrap möchten, drücken wieVerwendung app.use() anstelle von Script-Tag in Knoten ausdrücken
app.use('/scripts', express.static(__dirname + '/node_modules/jquery/dist/js/jquery.min.js'));
app.use('/link', express.static(__dirname + '/node_modules/bootstrap/dist/css/bootstrap.min.css'));
app.use('/scripts', express.static(__dirname + '/node_modules/bootstrap/dist/js/bootstrap.min.js'));
statt
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/js/bootstrap.min.js"></script>
Bitte helfen Sie mir, danke!
Uhm ist, was? 'app.use' hat wirklich nichts mit Skript-Tags im Browser, es sei denn, Sie erstellen eine Middleware, die das tatsächlich tut? – adeneo
Ich weiß nicht, wie man ersetzt, bitte zeigen Sie mir einen Weg – Cver