简体   繁体   English

如何将Marionette js应用程序从1.x升级到2.x?

[英]How do I upgrade my Marionette js app from 1.x to 2.x?

It looks like there was a pretty massive shift from 1.x to 2.x. 从1.x到2.x似乎有很大的转变。 My app doesn't work anymore. 我的应用程序不再起作用。 No errors. 没有错误。 Just doesn't work. 只是不起作用。 I'm 1.8.3 trying to get to 2.4.1 to take advantage of the new collection optimizations. 我正在尝试1.8.3升级到2.4.1,以利用新的集合优化。

I see there is a tool to help with the upgrade: 我看到有一个工具可以帮助您进行升级:

Marionette Upgrade 木偶升级

But it requires Python knowledge to run it. 但是它需要Python知识才能运行它。 I know nothing about Python. 我对Python一无所知。 The instructions for running look pretty foreign to me. 对我来说,跑步说明看起来很陌生。 I did install the latest version of Python on my Windows 7 machine but I'm just not understanding the instructions on running the tool. 我确实在Windows 7计算机上安装了最新版本的Python,但我只是不了解有关运行该工具的说明。

Is this the only approach to upgrading? 这是唯一的升级方法吗?

The biggest "issue" is probably the "start" event. 最大的“问题”可能是“开始”事件。 Before, you would listen for the "initialize:after" event to do stuff when the app starts, but that event has been renamed "start". 之前,您会在应用启动时侦听“ initialize:after”事件以进行操作,但是该事件已重命名为“ start”。

Also, make sure to read through https://docs.google.com/document/d/1fuXb9N5LwmdPn-teMwAo3c8JTx6ifUowbqFY1NNSdp8/edit# : you'll probably recognize bits of your code that need to be updated. 另外,请务必通读https://docs.google.com/document/d/1fuXb9N5LwmdPn-teMwAo3c8JTx6ifUowbqFY1NNSdp8/edit# :您可能会识别出需要更新的代码。

You could manually run all the search and replaces the tool does by starting here: 您可以从此处开始手动运行所有搜索并替换该工具所做的工作:

https://github.com/marionettejs/Marionette.Upgrade/blob/master/upgrade.py#L108 https://github.com/marionettejs/Marionette.Upgrade/blob/master/upgrade.py#L108

left side strings are old, right side new. 左侧的弦很旧,右侧的弦很新。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何从 TensorFlow 1.x 迁移到 TensorFlow 2.x - How to migrate from TensorFlow 1.x to TensorFlow 2.x 如何将Django-Haystack中的SearchSite从1.X迁移到2.X? - How to migrate SearchSite in Django-Haystack from 1.X to 2.X? 如何使用 Ansible 1.x API 列出主机 - How do I list hosts using Ansible 1.x API 将 keras.backend.conv2d 从 Keras 1.x 迁移到 2.x - Migrating keras.backend.conv2d from Keras 1.x to 2.x TF 1.x 中的代码可以读取使用 TF 2.x 编写的 tfrecords 文件吗? - Can code from TF 1.x read a tfrecords file written using TF 2.x? 如何在Python 2.x中对对象执行自省? - How Do I Perform Introspection on an Object in Python 2.x? 如何在Python 2.x中检查输入是字符串还是int? - How do I check if an input is a string or int in Python 2.x? 将 Tensorflow 1.x 代码重写为 tensorflow 2.x - Rewriting Tensorflow 1.x code to tensorflow 2.x 如何处理已使用Python 2.x从文件中读取的列表中的数据? - How do I manipulate data in a list that has been read in from a file using Python 2.x? Python 2.x 到 3.x - Append 语法错误:如何使其与 Python 3.x 从 2.x 兼容。 - Python 2.x to 3.x - Append Syntaxerror: how to make it compatibale with Python 3.x from 2.x?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM