我正在关注this document。
npm install -g polymer-cli
git clone https://github.com/PolymerLabs/start-polymer3.git
cd start-polymer3
npm install
polymer serve
这有效。但是,如果我运行python -m http.server
而不是polymer serve
,它将无法正常工作。
有什么区别?
答案 0 :(得分:0)
这取决于您的python版本。使用Python -V签出,然后尝试;
# If Python version returned above is 3.X
python3 -m http.server
# On windows try "python" instead of "python3"
# If Python version returned above is 2.X
python -m SimpleHTTPServer