0
I created a file _Scriptspartial and inside that file is javascript code.
Follows file _Layout:
<!DOCTYPE html>
<html>
<head>
<partial name="_Favicons" />
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>@ViewData["Title"]</title>
</head>
<body>
<partial name="_ScriptsPartial" />
</body>
</html>
Follow the file code _Scriptspartial:
$('div.dropdown-menu')
.append('<h1><span class="badge badge-secondary">Notificação</span></h1>');
See the result:
This problem happens only by javascript code.
I already converted the encoding to utf-8 from the file _Scriptpartial and see VS2017 editor output:
Some solution ?
What is the encoding of your file?
– lazyFox
@lazyFox here is how ANSI, Visual Studio creates this default file.
– Matheus Miranda
Exchange for
UTF-8
.– Augusto Vasques
@Augustovasques I’ll have to change the coding to UTF-8 using note block while creating new files from Visual Studio 2017 ?
– Matheus Miranda
Speaking of the generated html
<head><meta charset="UTF-8"></head>
.– Augusto Vasques
@Augustovasques Here’s how
<meta charset="utf-8" />
– Matheus Miranda