Chrome扩展程序-用户可以使用我的源代码吗? [英] Chrome extension -- will my source code be available to users?

查看:85
本文介绍了Chrome扩展程序-用户可以使用我的源代码吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我即将发布我的第一个chrome扩展程序到chrome网上商店.他们希望压缩并上传代码.一旦获得批准,如果我理解正确的话,它将以.crx文件的形式提供给用户.

I'm about to release my first chrome extension to chrome web store. They want the code to be zipped and uploaded. And once through approval it will be available to users as .crx files, if I understand it correctly.

但是这些crx文件是扩展名为.crx的简单zip文件吗?如果是这样,用户将无法获取源代码吗?

But these crx files are simple zip file with .crx extension right? If so, won't users be able to get hold of the source code?

这意味着,我可能会看到在我的扩展程序旁边的网上商店中还有100多个源代码版本. :(

Which means, I may get to see 100 more versions of my source code floating around the web store alongside my extension. :(

是否有阻止用户掌握源代码的地方?

Is there anyway to prevent the user from getting hold of the source code?

推荐答案

为您的扩展提供源代码是将某些东西还给开源社区的最简单方法.由于您至少使用了一个开源应用程序(Chrome),因此您应该考虑将项目进行开源采购以偿还债务.

Providing source code to your extensions is the simplest way to give something back to the open source community. Since you are using at least one open source application (Chrome) you should think about open-sourcing your projects as paying back the debt.

您还应该了解GitHub/Bitbucket个人资料是开发人员产品组合.许多公司在提供工作之前都会考虑这些问题.如今,每个优秀的开发人员都有大量的开源项目.这样一来,任何人都可以了解他们编写的代码的质量,与其他开发人员的协作程度,对细节的重视程度等.

You should also understand that GitHub/Bitbucket profile is a developer portfolio. Many companies look at these before offering a job. Nowadays, each and every good developer has an extensive list of open source projects. This allows anyone to get an idea of how good is the code they write, how well they can collaborate with other developers, how much attention do they pay to the details etc.

最后但并非最不重要的一点是,如果您的扩展确实非常好,如果您不断对其进行维护并开发新功能并且用户喜欢使用它,则可以确定它会保护自己免受任何形式的复制.如果您开源代码,那么您肯定会找到一些合作者,这些合作者将提供翻译,新功能并帮助您修复错误.

Last but not least, if your extension is really good, if you constantly maintain it and develop new features and your users enjoy using it, you may be sure that it will defend itself from any kind of copies. If you open source your code you'll surely find some collaborators that will provide translations, new features and will help you to fix the bugs.

无论如何,您的问题的答案是:如果您担心有人会使用您的JavaScript代码,则可以美化这样做会很痛苦.其他解决方案是编写 NPAPI插件

Anyway, an answer to your question is this: if you are afraid that someone will use your JavaScript code you can obfuscate it. Of course, obfuscated code can be prettified by someone who is desperate to read it but without the comments and meaningful variable names it will be a pain to do so. Other solution is to write a NPAPI plugin or Native Client app because these allow you to compile parts of the code.

这篇关于Chrome扩展程序-用户可以使用我的源代码吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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