Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

Working with Simple Cordova App #35

Closed
axemclion opened this issue Jul 28, 2015 · 3 comments
Closed

Working with Simple Cordova App #35

axemclion opened this issue Jul 28, 2015 · 3 comments
Assignees
Milestone

Comments

@axemclion
Copy link

One of the hooks in this apps looks for a W3C Manifest.json. As a result, this plugin cannot be added to a regular Cordova hook.

Does it make sense to skip the manifest steps if such a file does not exist ? This way, the plugin can be added to Cordova also.

@f2bo
Copy link
Contributor

f2bo commented Jul 29, 2015

Just to be clear, this plugin is meant to be added to a Cordova app. Its main purpose is to allow the creation of hosted web apps. That is, apps where the content is hosted on a web server.

To do its job, it needs some details about the web content it should host. The way in which it obtains this information is to use a W3C manifest, which is a standardized mechanism to publish metadata for a web application (see http://www.w3.org/TR/appmanifest/). All the W3C manifest members are optional but the more information it has, for example, the app name and its icons, will allow it to create a more polished application. At the very least, the plugin needs the starting URL of the web application.

If your concern is that a site that you wish to host does not publish its own manifest, you can always create one for it, name it manifest.json, and copy it to the root of your Cordova project. For example:

{
    "start_url": "http://www.yoursite.com/",
    "short_name": "WwwYoursiteCom"
}

Let me know if you have any other questions.

@f2bo f2bo closed this as completed Jul 29, 2015
@f2bo f2bo mentioned this issue Jul 29, 2015
@axemclion
Copy link
Author

cc @boyofgreen

I agree that this plugins is meant to be added in a Cordova app. However, the Cordova app does not need to have a manifest file. The Cordova app could simply be one that I created using the command line and that app will not have the manifest.

Making the hooks check for the W3C file in such a case fails the compile step. Following Cordova's modularity principle, maybe you could spilt this plugin into 2, one that is responsible for displaying the offline page (which is super useful in a non cordova case), and another that adds the plugins ,etc.

@boyofgreen
Copy link
Contributor

I'm going to open this issue back up to experiment in verion 0.1.5. I've had this ask come up again, and I think it will be of little cost to make it work in that sceneio where the developer doesn't have a concept of "web manifest" we can use general info that they can then go and override in the cordova manifest

@boyofgreen boyofgreen reopened this Aug 25, 2015
@boyofgreen boyofgreen added this to the release-0.1.5 milestone Aug 25, 2015
@boyofgreen boyofgreen modified the milestones: release-0.1.6, release-0.1.5 Oct 30, 2015
@boyofgreen boyofgreen modified the milestones: release-0.3, release-0.1.6 Apr 13, 2016
@boyofgreen boyofgreen assigned cbarkerms and unassigned DaveVoyles Apr 20, 2016
boyofgreen added a commit that referenced this issue Apr 22, 2016
remove hard requirement for w3c manifest, this finally addresses the issue #35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants