导入re_path即可。
from django.URLs import re_path
urlpatterns = [re_path(r"^$", function)]
django4.0path不能用正则表达式
最新推荐文章于 2024-03-08 16:28:45 发布
导入re_path即可。
from django.URLs import re_path
urlpatterns = [re_path(r"^$", function)]