Razor 类库中的图像 [英] Images in Razor Class Library

查看:27
本文介绍了Razor 类库中的图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以使用图像和其他文件类型,例如 css/js/etc.在 Razor 类库中?我在尝试让 Razor 类库中的图像和 css 显示在 .Net Core 2.1 MVC 应用程序中时遇到问题.

Is it possible to use images and other file types such as css/js/etc. in a Razor Class library? I'm having an issue trying to get the images and css in the Razor Class Library to show up in a .Net Core 2.1 MVC application.

我们曾经使用文件提供程序和 C# 类库,但我觉得 Razor 类库现在应该能够通过简单地在项目中添加对该库的引用来实现这一点.

We used to use the File Provider and a C# class library but I feel like the Razor Class Library should be able to accomplish this now by simply adding a reference to the library in a project.

推荐答案

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆