• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Polymer - Google

#1
I would like to use Polymer web component in the views of CI. It works fine when I load the view throgth a controller, but when I try to load the view with controller/method or controller/method/parameter dies nit work because do not get the correct url declared un the import links?
Please could you suggest what should be the structure of the directories? Thanks.
Reply

#2
Hi, I don't know anything about Polymer but the problem you describe is of hard coded relative links that are wrong. Surely Polymer gives you a way to do relative links so you can use /assets/js/myjsfile.js which at least is relative to the root and can be made to work. Links that start without the / are relative to the page the link is on. That is a problem.

Also, surely Polymer can do full links, so you control the entire link http://www.mysite.com/assets/js/myjsfile.js etc. That would also solve the problem.

The other possible answer is to use polymer generated html that does not include js, css links and add them after from the controller in normally generated views.

There are so many things that could be causing the issue but there are also many possible solutions. The aim is to get away from relative links that depend on the url of the page the link is on.

Hope that helps, and makes sense,

Paul
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.