// The first parameter is the script path, the second parameter is a list of html attributes as key value pairs.
@Html.Script(Url.WidgetContent("/Mvc/Views/Scripter/myscript.js"), new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("defer", "defer")})

// The first parameter is the script path, the second is the section in which to render the script, the third indicates whether to throw an exception if the specified section does not exist, and the last parameter is a list of html attributes as key value pairs.
@Html.Script(Url.WidgetContent("/Mvc/Views/Scripter/myscript.js"), "head", true, new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("defer", "defer")})

// The first parameter is the script path, the second is the section in which to render the script, the third indicates whether to throw an exception if the specified section does not exist, the fourth parameter indicates whether to use script manager (if it exists) when registering a JavaScript reference. Keep in mind that there is a limitation, if you use script manager, attributes will not be added to the script reference. The last  parameter is a list of html attributes as key value pairs.
@Html.Script(Url.WidgetContent("/Mvc/Views/Scripter/myscript.js"), "head", true, false, new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("defer", "defer")})

// The first parameter is the script reference, the second parameter is a list of html attributes as key value pairs.
@Html.Script(ScriptRef.JQuery, new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("defer", "defer")})

// The first parameter is the script reference, the second parameter is the section in which you want to render the reference, the third parameter is a list of html attributes as key value pairs.
@Html.Script(ScriptRef.JQuery, "head", new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("defer", "defer")})

// The first parameter is the script reference, the second is the section in which to render the script, the third parameters indicates whether to throw an exception if the specified section does not exist, the fourth parameter indicates whether to use script manager (if it exists) when registering a JavaScript reference. Keep in mind that there is a limitation, if you use script manager, attributes will not be added to the script reference. The last  parameter is a list of html attributes as key value pairs.
@Html.Script(ScriptRef.JQuery, "head", false, false, new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("defer", "defer")})

// The first parameter is the path to the CSS file, the second parameter is the section in which the stylesheet will be rendered, the last parameter is a list of html attributes as key value pairs.
@Html.StyleSheet(Url.WidgetContent("~/ResourcePackages/Bootstrap4/assets/dist/css/mycss.css"), new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("data-index-number", "12314")})

// The first parameter is the path to the CSS file, the second parameter is the section in which the stylesheet will be rendered, the last parameter is a list of html attributes as key value pairs.
@Html.StyleSheet(Url.WidgetContent("~/ResourcePackages/Bootstrap4/assets/dist/css/mycss.css"),"head", false, new List<KeyValuePair<string, string>>() { new KeyValuePair<string, string>("data-index-number", "12314")})