瀏覽代碼

Create empty directory for pc.get_asset_path() when .web init (#1171)

Milo Chen 2 年之前
父節點
當前提交
a846953926
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      pynecone/utils/prerequisites.py

+ 1 - 0
pynecone/utils/prerequisites.py

@@ -209,6 +209,7 @@ def initialize_web_directory():
     path_ops.rm(os.path.join(constants.WEB_TEMPLATE_DIR, constants.NODE_MODULES))
     path_ops.rm(os.path.join(constants.WEB_TEMPLATE_DIR, constants.PACKAGE_LOCK))
     path_ops.cp(constants.WEB_TEMPLATE_DIR, constants.WEB_DIR)
+    path_ops.mkdir(constants.WEB_ASSETS_DIR)
 
     # Write the current version of distributed pynecone package to a PCVERSION_APP_FILE."""
     with open(constants.PCVERSION_APP_FILE, "w") as f: