donRumatta
donRumatta

Reputation: 842

PhoneGap architecture design

I'm going to write my first phonegap app (for tablets) and i'm not sure in what way I should organize its structure:

  1. one .html file with many divs, that I change with js.
  2. many .html files

What is the best practice in PhoneGap development?

Upvotes: 1

Views: 195

Answers (1)

Sunil Dodiya
Sunil Dodiya

Reputation: 2615

Well, Both method is good but i would suggest 2nd option because its easy to manage separate files rather then one file.

You can get your html files contain using

$.get(file_name, function(data){
   console.log(data);
});

jquery function and you can innerHtml to any DIV or Document Body

Upvotes: 1

Related Questions