SlideShare une entreprise Scribd logo
1  sur  44
Télécharger pour lire hors ligne
CONFIDENTIAL & PROPRIETARY
Page	
  Title
SUBTITLE
1
When	
  	
  
Web	
  
meet	
  	
  
Na6ve	
  App
Eric	
  Chuang
當網⾴頁遇上原⽣生App
CONFIDENTIAL & PROPRIETARY
When	
  Web	
  meet	
  Na6ve	
  App
Yahoo	
  Taiwan	
  Mobile	
  Team	
  
Eric	
  Chuang
2
CONFIDENTIAL & PROPRIETARY
About	
  Me
• Eric	
  Chuang	
  (ddsakura)	
  
• WebConf	
  2012	
  Speaker	
  
• Yahoo	
  Lead	
  Engineer
3
• Full	
  Stack	
  Engineer	
  ?	
  
– Developed	
  Yahoo	
  E-­‐Commerce	
  Mobile	
  Web	
  
– Developed	
  Yahoo	
  E-­‐Commerce	
  超級商城	
  iPhone	
  App	
  
– Developed	
  Yahoo	
  E-­‐Commerce	
  拍賣	
  Android	
  App
Auc6on	
  Android	
  App
猜猜哪裡是	
  Web?
Web	
  in	
  Auc6on	
  Android	
  App
CONFIDENTIAL & PROPRIETARY
What	
  is	
  Webview
• A	
  View	
  that	
  displays	
  web	
  pages.	
  
• Android	
  
– Since	
  API	
  1	
  
• iOS	
  
– UIWebView	
  
– MKWebView
7
CONFIDENTIAL & PROPRIETARY
曾經我以為
Android	
  Webview	
  >	
  iOS	
  UIWebview	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  (can	
  not	
  use	
  Nitro	
  JavaScript	
  Engine	
  )
8
Android	
  Webview	
  ==	
  Android	
  Browser
CONFIDENTIAL & PROPRIETARY
9
hWp://beta.html5test.com/
CONFIDENTIAL & PROPRIETARY hWp://beta.html5test.com/
CONFIDENTIAL & PROPRIETARY
結果…
11
Android	
  Webview	
  !=	
  Android	
  Browser
Android	
  Webview	
  v.s.	
  iOS	
  UIWebview/MKWebview
CONFIDENTIAL & PROPRIETARY
12
CONFIDENTIAL & PROPRIETARY
Android	
  Webview	
  version
• Android	
  4.4	
  
– Chromium	
  30
13
• Android	
  4.4.3	
  
– Chromium	
  33
• Android	
  5.0	
  
– Chromium	
  37
• And	
  in	
  google	
  play	
  
– hWps://play.google.com/store/apps/details?id=com.google.android.webview	
  
CONFIDENTIAL & PROPRIETARY
14
CONFIDENTIAL & PROPRIETARY
Android	
  Webview	
  version
• Android	
  before	
  4.4	
  
– Old	
  Webview	
  
– Vendor	
  may	
  “improve”	
  their	
  webview	
  
– ref:	
  hWp://slides.com/html5test/the-­‐android-­‐browser#/12
15
CONFIDENTIAL & PROPRIETARY
SO	
  WE	
  NO	
  LONGER	
  HAVE	
  
ONE	
  WEBVIEW	
  FOR	
  
EACH	
  ANDROID	
  VERSION
BUT
16
ONE	
  FOR	
  SAMSUNG,
AND	
  ONE	
  FOR	
  HTC,
AND	
  ONE	
  FOR	
  ...
CONFIDENTIAL & PROPRIETARY
Let’s	
  start	
  webview
• We	
  need	
  permission
17
<uses-­‐permission	
  android:name="android.permission.INTERNET"	
  />
• Basic	
  usage
WebView	
  mWebview	
  =	
  new	
  WebView(this);	
  
mWebview.loadUrl(“file:///android_asset/www/index.html”);	
  
mWebview.loadUrl(“hWp://tw.yahoo.com/“);	
  
String	
  summary	
  =	
  “<html><body>Hello	
  World</body></html>”;	
  
mWebview.loadData(summary,	
  "text/html",	
  null);	
  
CONFIDENTIAL & PROPRIETARY
Local	
  Assets
• file:///android_asset/	
  
– The	
  assets	
  directory	
  of	
  an	
  Android	
  app	
  is	
  located	
  at	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
src/main/assets	
  inside	
  your	
  Android	
  Studio	
  project.
18
CONFIDENTIAL & PROPRIETARY
How	
  about	
  JavaScript
• WebViews	
  don't	
  allow	
  JavaScript	
  by	
  default.
19
//	
  Enable	
  JavascriptWebSepngs	
  	
  
webSepngs	
  =	
  mWebView.getSepngs();	
  
webSepngs.setJavaScriptEnabled(true);
CONFIDENTIAL & PROPRIETARY
Configure	
  webview
• Websepngs	
  
– setJavaScriptEnabled	
  	
  
• The	
  default	
  is	
  false.	
  
– setGeoloca6onEnabled	
  	
  
• The	
  default	
  is	
  true.	
  	
  
• ACCESS_COARSE_LOCATION,	
  ACCESS_FINE_LOCATION	
  
– setBuiltInZoomControls	
  	
  
• The	
  default	
  is	
  false.	
  	
  
– setDomStorageEnabled	
  	
  
• The	
  default	
  value	
  is	
  false.
20hWp://developer.android.com/reference/android/webkit/WebSepngs.html
CONFIDENTIAL & PROPRIETARY
Configure	
  webview	
  cont.
• UserAgent	
  
– getUserAgentString	
  
– setUserAgentString
21
Mozilla/5.0	
  (Linux;	
  U;	
  Android	
  4.1.1;	
  en-­‐gb;	
  Build/KLP)	
  AppleWebKit/534.30	
  (KHTML,	
  like	
  Gecko)	
  Version/4.0	
  Safari/534.30
Mozilla/5.0	
  (Linux;	
  Android	
  4.4;	
  Nexus	
  5	
  Build/_BuildID_)	
  AppleWebKit/537.36	
  (KHTML,	
  like	
  Gecko)	
  Version/4.0	
  Chrome/
30.0.0.0	
  Mobile	
  Safari/537.36
hWps://developer.chrome.com/mul6device/user-­‐agent
WebViewClient
WebChromeClient
CONFIDENTIAL & PROPRIETARY
WebViewClient
• Instance	
  of	
  WebViewClient	
  that	
  is	
  the	
  client	
  callback.	
  
• It	
  will	
  be	
  called	
  when	
  things	
  happen	
  that	
  impact	
  the	
  
rendering	
  of	
  the	
  content,	
  
• Func6ons	
  
– onLoadResource	
  
– onPageStart	
  
– onPageFinish	
  
– onReceiveError	
  
– shouldInterceptRequest	
  
23
hWp://developer.android.com/reference/android/webkit/WebViewClient.html
CONFIDENTIAL & PROPRIETARY
WebChromeClient
• Instance	
  of	
  WebChromeClient	
  for	
  handling	
  all	
  chrome	
  
func6ons.	
  
• This	
  class	
  is	
  called	
  when	
  something	
  that	
  might	
  impact	
  a	
  
browser	
  UI	
  happens,	
  for	
  instance,	
  progress	
  updates	
  and	
  
JavaScript	
  alerts	
  are	
  sent	
  here	
  	
  
• Func6ons	
  
– onCloseWindow	
  
– onCreateWindow	
  
– onJsAlert	
  
– onJsPrompt	
  
– onJsConfirm	
  
24
hWp://developer.android.com/reference/android/webkit/WebChromeClient.html
CONFIDENTIAL & PROPRIETARY
Example	
  between	
  WebViewClient	
  and	
  WebChromeClient
25
CONFIDENTIAL & PROPRIETARY
Handling	
  Links
• Default	
  behavior:	
  load	
  that	
  URL	
  of	
  the	
  link	
  in	
  the	
  default	
  
Android	
  browser.	
  
26
Intercept	
  the	
  url	
  !!
CONFIDENTIAL & PROPRIETARY
Intercep6ng	
  WebView	
  HTTP	
  Requests
• public	
  boolean	
  shouldOverrideUrlLoading	
  (WebView	
  view,	
  
String	
  url)	
  
– Give	
  the	
  host	
  applica6on	
  a	
  chance	
  to	
  take	
  over	
  the	
  control	
  when	
  a	
  
new	
  url	
  is	
  about	
  to	
  be	
  loaded	
  in	
  the	
  current	
  WebView.	
  
27
CONFIDENTIAL & PROPRIETARY
Intercep6ng	
  example	
  1
28
if	
  (path.contains(ECWebView.WEB_URL_ECAUCTION_TYPE_PRODUCT_ITEM))	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  showItemPage(url);	
  //	
  call	
  na6ve	
  component	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  return	
  true;	
  
}	
  
if	
  (path.contains(ECWebView.WEB_URL_ECAUCTION_TYPE_SELLER_BOOTH))	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  showSellerBooth(url);	
  //	
  call	
  na6ve	
  component	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  return	
  true;	
  
}
CONFIDENTIAL & PROPRIETARY
Intercep6ng	
  example	
  2
29
if (whiteList.indexOf(host) != -1) {
toggleLoadingUI(true);
return false;
}
CONFIDENTIAL & PROPRIETARY
From	
  JavaScript	
  to	
  Java	
  -­‐	
  Android	
  Part
30
public	
  class	
  WebAppInterface	
  {	
  
	
  	
  	
  	
  Context	
  mContext;	
  
	
  	
  	
  	
  /**	
  Instan6ate	
  the	
  interface	
  and	
  set	
  the	
  context	
  */	
  
	
  	
  	
  	
  WebAppInterface(Context	
  c)	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  mContext	
  =	
  c;	
  
	
  	
  	
  	
  }	
  
	
  	
  	
  	
  /**	
  Show	
  a	
  toast	
  from	
  the	
  web	
  page	
  */	
  
	
  	
  	
  	
  @JavascriptInterface	
  
	
  	
  	
  	
  public	
  void	
  showToast(String	
  toast)	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  Toast.makeText(mContext,	
  toast,	
  Toast.LENGTH_SHORT).show();	
  
	
  	
  	
  	
  }	
  
}
webView.addJavascriptInterface(new	
  WebAppInterface(this),	
  "Android");
CONFIDENTIAL & PROPRIETARY
From	
  JavaScript	
  to	
  Java	
  -­‐	
  HTML	
  Part
31
<input	
  type="buWon"	
  value="Say	
  hello"	
  onClick="showAndroidToast('Hello	
  Android!')"	
  />	
  
<script	
  type="text/javascript">	
  
	
  	
  	
  	
  func6on	
  showAndroidToast(toast)	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  Android.showToast(toast);	
  
	
  	
  	
  	
  }	
  
</script>
CONFIDENTIAL & PROPRIETARY
From	
  Java	
  to	
  JavaScript
32
mWebView.loadUrl("javascript:window.cartList.closeOverlay()");
CONFIDENTIAL & PROPRIETARY
Naviga6ng	
  web	
  page	
  history
33
@Override	
  
public	
  boolean	
  onKeyDown(int	
  keyCode,	
  KeyEvent	
  event)	
  {	
  
	
  	
  	
  	
  //	
  Check	
  if	
  the	
  key	
  event	
  was	
  the	
  Back	
  buWon	
  and	
  if	
  there's	
  history	
  
	
  	
  	
  	
  if	
  ((keyCode	
  ==	
  KeyEvent.KEYCODE_BACK)	
  &&	
  myWebView.canGoBack())	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  myWebView.goBack();	
  
	
  	
  	
  	
  	
  	
  	
  	
  return	
  true;	
  
	
  	
  	
  	
  }	
  
	
  	
  	
  	
  //	
  If	
  it	
  wasn't	
  the	
  Back	
  key	
  or	
  there's	
  no	
  web	
  page	
  history,	
  bubble	
  up	
  to	
  the	
  default	
  
	
  	
  	
  	
  //	
  system	
  behavior	
  (probably	
  exit	
  the	
  ac6vity)	
  
	
  	
  	
  	
  return	
  super.onKeyDown(keyCode,	
  event);	
  
}
CONFIDENTIAL & PROPRIETARY
Cache	
  Web	
  Resources
34
@Override	
  
public	
  WebResourceResponse	
  shouldInterceptRequest(WebView	
  view,	
  String	
  url)	
  {	
  
	
  	
  	
  	
  if(url.startsWith("hWp://mydomain.com/ar6cle/")	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  String	
  cacheFileName	
  =	
  url.substring(url.lastIndexOf("/"),	
  url.length());	
  
	
  	
  	
  	
  	
  	
  	
  	
  this.urlCache.register(url,	
  cacheFileName,	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  "text/html",	
  "UTF-­‐8",	
  60	
  *	
  UrlCache.ONE_MINUTE);	
  
	
  	
  	
  	
  }	
  
	
  	
  	
  	
  return	
  this.urlCache.load(url);	
  
}	
  
CONFIDENTIAL & PROPRIETARY
Android	
  Lollipop
• Mixed	
  content	
  issue
35
	
  	
  	
  	
  	
  	
  	
  	
  if	
  (android.os.Build.VERSION.SDK_INT	
  >=	
  21)	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  webSepngs.setMixedContentMode(WebSe<ngs.MIXED_CONTENT_ALWAYS_ALLOW);	
  
	
  	
  	
  	
  	
  	
  	
  	
  }
CONFIDENTIAL & PROPRIETARY
Cookie
• CookieManager	
  
– Manages	
  the	
  cookies	
  used	
  by	
  an	
  applica6on's	
  WebView	
  instances.	
  
• setCookie(String	
  url,	
  String	
  value)	
  
• getCookie(url)	
  
• CookieSyncManager	
  
– This	
  class	
  was	
  deprecated	
  in	
  API	
  level	
  21.	
  The	
  WebView	
  now	
  
automa6cally	
  syncs	
  cookies	
  as	
  necessary.	
  You	
  no	
  longer	
  need	
  to	
  
create	
  or	
  use	
  the	
  CookieSyncManager.	
  To	
  manually	
  force	
  a	
  sync	
  you	
  
can	
  use	
  the	
  CookieManager	
  method	
  flush()	
  which	
  is	
  a	
  synchronous	
  
replacement	
  for	
  sync().	
  
36
CONFIDENTIAL & PROPRIETARY
Handle	
  HWp	
  Error
37
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  @Override	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  public	
  void	
  onReceivedError(WebView	
  view,	
  int	
  errorCode,	
  String	
  descrip6on,	
  String	
  
failingUrl)	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  …	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  }	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  @Override	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  public	
  void	
  onReceivedSslError(WebView	
  view,	
  SslErrorHandler	
  handler,	
  SslError	
  error)	
  {	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  handler.proceed();	
  //	
  Ignore	
  SSL	
  cer6ficate	
  errors	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  }
CONFIDENTIAL & PROPRIETARY
Handle	
  HWp	
  Error	
  bug
• onReceivedError	
  STILL	
  does	
  not	
  receive	
  HTTP	
  Errors	
  
– hWps://code.google.com/p/android/issues/detail?id=82069
38
@Override
public void onPageFinished(WebView view, String url) {
if (WEBPAGE_ERROR_HTML_TITLE.indexOf(mWebContentTitle) != -1) {
mListener.onPageReceivedError(view, WEBPAGE_ERROR_CODE, mWebContentTitle, url);
}
}
CONFIDENTIAL & PROPRIETARY
Debugging	
  webview
• Requirements	
  
– Chrome	
  32	
  or	
  later	
  installed	
  on	
  your	
  development	
  machine.	
  
– A	
  USB	
  cable	
  to	
  connect	
  your	
  Android	
  device.	
  
– For	
  app	
  debugging:	
  Android	
  4.4+	
  and	
  a	
  WebView	
  configured	
  for	
  
debugging.
39
	
  if	
  (Build.VERSION.SDK_INT	
  >=	
  Build.VERSION_CODES.KITKAT)	
  {	
  
	
  	
  	
  	
  	
  	
  WebView.setWebContentsDebuggingEnabled(true);	
  
	
  	
  }
CONFIDENTIAL & PROPRIETARY
Debugging	
  webview	
  cont.
• The	
  chrome://inspect	
  page	
  displays	
  a	
  list	
  of	
  debug-­‐
enabled	
  WebViews	
  on	
  your	
  device.	
  
• To	
  start	
  debugging,	
  click	
  inspect	
  below	
  the	
  WebView	
  you	
  
want	
  to	
  debug.	
  	
  
• As	
  of	
  KitKat	
  4.4.3,	
  screencast	
  is	
  available	
  for	
  both	
  browser	
  
tabs	
  and	
  Android	
  WebViews.
40
CONFIDENTIAL & PROPRIETARY
Tes6ng	
  with	
  Webview
• Robo6um	
  
– hWps://code.google.com/p/robo6um/
41
	
  	
  	
  	
  	
  	
  	
  	
  //	
  Type	
  in	
  text	
  box	
  
	
  	
  	
  	
  	
  	
  	
  	
  WebElement	
  txtSearch	
  =	
  solo.getWebElement(By.name("q"),	
  0);	
  
	
  	
  	
  	
  	
  	
  	
  	
  txtSearch.setTextContent("Hello");	
  
	
  	
  	
  	
  	
  	
  	
  	
  //	
  click	
  buWon	
  
	
  	
  	
  	
  	
  	
  	
  	
  WebElement	
  btnSearch	
  =	
  (WebElement)	
  solo.getWebElement(By.name("btnG"),	
  0);	
  
	
  	
  	
  	
  	
  	
  	
  	
  solo.clickOnWebElement(btnSearch);
CONFIDENTIAL & PROPRIETARY
Project	
  that	
  Improve	
  Webview
• Crosswalk	
  
– hWps://crosswalk-­‐project.org/	
  
– Develop	
  around	
  device	
  fragmenta6on	
  
– Provide	
  a	
  feature	
  rich	
  experience	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
all	
  on	
  Android	
  4.x	
  devices	
  
– Easily	
  debug	
  with	
  Chrome	
  DevTools	
  
– Improve	
  the	
  performance	
  of	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
HTML,	
  CSS,	
  and	
  JavaScript
42
CONFIDENTIAL & PROPRIETARY
Conclusion
• 這不是⾮非⿊黑即⽩白的世界	
  
– Web	
  跟	
  Na6ve	
  App	
  亦然	
  
• 讓	
  Web	
  和	
  Na6ve	
  App	
  共舞	
  
– 提供使⽤用者最好的體驗
43
CONFIDENTIAL & PROPRIETARY
Thank	
  you
44
Eric	
  Chuang
hKp://bit.ly/1JkyR1W

Contenu connexe

Tendances

Spark IT 2011 - Java EE 6 Workshop
Spark IT 2011 - Java EE 6 WorkshopSpark IT 2011 - Java EE 6 Workshop
Spark IT 2011 - Java EE 6 WorkshopArun Gupta
 
Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017Matt Raible
 
A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019
A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019
A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019Matt Raible
 
Bootiful Development with Spring Boot and React - UberConf 2018
Bootiful Development with Spring Boot and React - UberConf 2018Bootiful Development with Spring Boot and React - UberConf 2018
Bootiful Development with Spring Boot and React - UberConf 2018Matt Raible
 
Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020
Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020
Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020Matt Raible
 
Front End Development for Backend Developers - GIDS 2019
Front End Development for Backend Developers - GIDS 2019Front End Development for Backend Developers - GIDS 2019
Front End Development for Backend Developers - GIDS 2019Matt Raible
 
Choosing a Java Web Framework
Choosing a Java Web FrameworkChoosing a Java Web Framework
Choosing a Java Web FrameworkWill Iverson
 
Bootiful Development with Spring Boot and React - RWX 2017
Bootiful Development with Spring Boot and React - RWX 2017Bootiful Development with Spring Boot and React - RWX 2017
Bootiful Development with Spring Boot and React - RWX 2017Matt Raible
 
Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021Matt Raible
 
How to Win at UI Development in the World of Microservices - THAT Conference ...
How to Win at UI Development in the World of Microservices - THAT Conference ...How to Win at UI Development in the World of Microservices - THAT Conference ...
How to Win at UI Development in the World of Microservices - THAT Conference ...Matt Raible
 
Comparing JVM Web Frameworks - Rich Web Experience 2010
Comparing JVM Web Frameworks - Rich Web Experience 2010Comparing JVM Web Frameworks - Rich Web Experience 2010
Comparing JVM Web Frameworks - Rich Web Experience 2010Matt Raible
 
JAX-RS JavaOne Hyderabad, India 2011
JAX-RS JavaOne Hyderabad, India 2011JAX-RS JavaOne Hyderabad, India 2011
JAX-RS JavaOne Hyderabad, India 2011Shreedhar Ganapathy
 
Spark IT 2011 - Developing RESTful Web services with JAX-RS
Spark IT 2011 - Developing RESTful Web services with JAX-RSSpark IT 2011 - Developing RESTful Web services with JAX-RS
Spark IT 2011 - Developing RESTful Web services with JAX-RSArun Gupta
 
DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)
DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)
DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)Chen Cheng-Wei
 
Spring IO '15 - Developing microservices, Spring Boot or Grails?
Spring IO '15 - Developing microservices, Spring Boot or Grails?Spring IO '15 - Developing microservices, Spring Boot or Grails?
Spring IO '15 - Developing microservices, Spring Boot or Grails?Fátima Casaú Pérez
 
Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019
Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019
Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019Matt Raible
 
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG🎤 Hanno Embregts 🎸
 
淺談 Geb 網站自動化測試(JCConf 2014)
淺談 Geb 網站自動化測試(JCConf 2014)淺談 Geb 網站自動化測試(JCConf 2014)
淺談 Geb 網站自動化測試(JCConf 2014)Kyle Lin
 
Using React with Grails 3
Using React with Grails 3Using React with Grails 3
Using React with Grails 3Zachary Klein
 
Enterprise Build And Test In The Cloud
Enterprise Build And Test In The CloudEnterprise Build And Test In The Cloud
Enterprise Build And Test In The CloudCarlos Sanchez
 

Tendances (20)

Spark IT 2011 - Java EE 6 Workshop
Spark IT 2011 - Java EE 6 WorkshopSpark IT 2011 - Java EE 6 Workshop
Spark IT 2011 - Java EE 6 Workshop
 
Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017
 
A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019
A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019
A Gentle Introduction to Angular Schematics - Devoxx Belgium 2019
 
Bootiful Development with Spring Boot and React - UberConf 2018
Bootiful Development with Spring Boot and React - UberConf 2018Bootiful Development with Spring Boot and React - UberConf 2018
Bootiful Development with Spring Boot and React - UberConf 2018
 
Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020
Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020
Mobile Development with Ionic, React Native, and JHipster - AllTheTalks 2020
 
Front End Development for Backend Developers - GIDS 2019
Front End Development for Backend Developers - GIDS 2019Front End Development for Backend Developers - GIDS 2019
Front End Development for Backend Developers - GIDS 2019
 
Choosing a Java Web Framework
Choosing a Java Web FrameworkChoosing a Java Web Framework
Choosing a Java Web Framework
 
Bootiful Development with Spring Boot and React - RWX 2017
Bootiful Development with Spring Boot and React - RWX 2017Bootiful Development with Spring Boot and React - RWX 2017
Bootiful Development with Spring Boot and React - RWX 2017
 
Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021
 
How to Win at UI Development in the World of Microservices - THAT Conference ...
How to Win at UI Development in the World of Microservices - THAT Conference ...How to Win at UI Development in the World of Microservices - THAT Conference ...
How to Win at UI Development in the World of Microservices - THAT Conference ...
 
Comparing JVM Web Frameworks - Rich Web Experience 2010
Comparing JVM Web Frameworks - Rich Web Experience 2010Comparing JVM Web Frameworks - Rich Web Experience 2010
Comparing JVM Web Frameworks - Rich Web Experience 2010
 
JAX-RS JavaOne Hyderabad, India 2011
JAX-RS JavaOne Hyderabad, India 2011JAX-RS JavaOne Hyderabad, India 2011
JAX-RS JavaOne Hyderabad, India 2011
 
Spark IT 2011 - Developing RESTful Web services with JAX-RS
Spark IT 2011 - Developing RESTful Web services with JAX-RSSpark IT 2011 - Developing RESTful Web services with JAX-RS
Spark IT 2011 - Developing RESTful Web services with JAX-RS
 
DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)
DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)
DevOps叢林裡的小隊游擊戰術 (@ iThome DevOps 2015)
 
Spring IO '15 - Developing microservices, Spring Boot or Grails?
Spring IO '15 - Developing microservices, Spring Boot or Grails?Spring IO '15 - Developing microservices, Spring Boot or Grails?
Spring IO '15 - Developing microservices, Spring Boot or Grails?
 
Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019
Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019
Spring Boot APIs and Angular Apps: Get Hip with JHipster! KCDC 2019
 
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
 
淺談 Geb 網站自動化測試(JCConf 2014)
淺談 Geb 網站自動化測試(JCConf 2014)淺談 Geb 網站自動化測試(JCConf 2014)
淺談 Geb 網站自動化測試(JCConf 2014)
 
Using React with Grails 3
Using React with Grails 3Using React with Grails 3
Using React with Grails 3
 
Enterprise Build And Test In The Cloud
Enterprise Build And Test In The CloudEnterprise Build And Test In The Cloud
Enterprise Build And Test In The Cloud
 

Similaire à When Web meet Native App

Predictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and ReduxPredictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and ReduxFITC
 
Hybrid App using WordPress
Hybrid App using WordPressHybrid App using WordPress
Hybrid App using WordPressHaim Michael
 
Node.js and Selenium Webdriver, a journey from the Java side
Node.js and Selenium Webdriver, a journey from the Java sideNode.js and Selenium Webdriver, a journey from the Java side
Node.js and Selenium Webdriver, a journey from the Java sideMek Srunyu Stittri
 
The WebView Role in Hybrid Applications
The WebView Role in Hybrid ApplicationsThe WebView Role in Hybrid Applications
The WebView Role in Hybrid ApplicationsHaim Michael
 
ASP.NET MVC Internals
ASP.NET MVC InternalsASP.NET MVC Internals
ASP.NET MVC InternalsVitaly Baum
 
Native Android Development with Spring
Native Android Development with SpringNative Android Development with Spring
Native Android Development with SpringRoy Clarkson
 
125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용NAVER D2
 
Test Automation using Ruby
Test Automation using Ruby Test Automation using Ruby
Test Automation using Ruby Sla Va
 
Creating Modular Test-Driven SPAs with Spring and AngularJS
Creating Modular Test-Driven SPAs with Spring and AngularJSCreating Modular Test-Driven SPAs with Spring and AngularJS
Creating Modular Test-Driven SPAs with Spring and AngularJSGunnar Hillert
 
Moving to the Client - JavaFX and HTML5
Moving to the Client - JavaFX and HTML5Moving to the Client - JavaFX and HTML5
Moving to the Client - JavaFX and HTML5Stephen Chin
 
Comparing Native Java REST API Frameworks - Seattle JUG 2022
Comparing Native Java REST API Frameworks - Seattle JUG 2022Comparing Native Java REST API Frameworks - Seattle JUG 2022
Comparing Native Java REST API Frameworks - Seattle JUG 2022Matt Raible
 
Developing ASP.NET Applications Using the Model View Controller Pattern
Developing ASP.NET Applications Using the Model View Controller PatternDeveloping ASP.NET Applications Using the Model View Controller Pattern
Developing ASP.NET Applications Using the Model View Controller Patterngoodfriday
 
Patterns Are Good For Managers
Patterns Are Good For ManagersPatterns Are Good For Managers
Patterns Are Good For ManagersAgileThought
 
決済サービスのSpring Bootのバージョンを2系に上げた話
決済サービスのSpring Bootのバージョンを2系に上げた話決済サービスのSpring Bootのバージョンを2系に上げた話
決済サービスのSpring Bootのバージョンを2系に上げた話Ryosuke Uchitate
 
Comparing Native Java REST API Frameworks - Devoxx France 2022
Comparing Native Java REST API Frameworks - Devoxx France 2022Comparing Native Java REST API Frameworks - Devoxx France 2022
Comparing Native Java REST API Frameworks - Devoxx France 2022Matt Raible
 
Advanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap IsAdvanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap IsGoogleTecTalks
 
Automating Hybrid Applications with Appium
Automating Hybrid Applications with AppiumAutomating Hybrid Applications with Appium
Automating Hybrid Applications with AppiumSauce Labs
 

Similaire à When Web meet Native App (20)

Predictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and ReduxPredictable Web Apps with Angular and Redux
Predictable Web Apps with Angular and Redux
 
Web deploy
Web deployWeb deploy
Web deploy
 
Hybrid App using WordPress
Hybrid App using WordPressHybrid App using WordPress
Hybrid App using WordPress
 
Web view
Web viewWeb view
Web view
 
Node.js and Selenium Webdriver, a journey from the Java side
Node.js and Selenium Webdriver, a journey from the Java sideNode.js and Selenium Webdriver, a journey from the Java side
Node.js and Selenium Webdriver, a journey from the Java side
 
The WebView Role in Hybrid Applications
The WebView Role in Hybrid ApplicationsThe WebView Role in Hybrid Applications
The WebView Role in Hybrid Applications
 
ASP.NET MVC Internals
ASP.NET MVC InternalsASP.NET MVC Internals
ASP.NET MVC Internals
 
Native Android Development with Spring
Native Android Development with SpringNative Android Development with Spring
Native Android Development with Spring
 
125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용125 고성능 web view-deview 2013 발표 자료_공유용
125 고성능 web view-deview 2013 발표 자료_공유용
 
Test Automation using Ruby
Test Automation using Ruby Test Automation using Ruby
Test Automation using Ruby
 
Creating Modular Test-Driven SPAs with Spring and AngularJS
Creating Modular Test-Driven SPAs with Spring and AngularJSCreating Modular Test-Driven SPAs with Spring and AngularJS
Creating Modular Test-Driven SPAs with Spring and AngularJS
 
Moving to the Client - JavaFX and HTML5
Moving to the Client - JavaFX and HTML5Moving to the Client - JavaFX and HTML5
Moving to the Client - JavaFX and HTML5
 
Comparing Native Java REST API Frameworks - Seattle JUG 2022
Comparing Native Java REST API Frameworks - Seattle JUG 2022Comparing Native Java REST API Frameworks - Seattle JUG 2022
Comparing Native Java REST API Frameworks - Seattle JUG 2022
 
Developing ASP.NET Applications Using the Model View Controller Pattern
Developing ASP.NET Applications Using the Model View Controller PatternDeveloping ASP.NET Applications Using the Model View Controller Pattern
Developing ASP.NET Applications Using the Model View Controller Pattern
 
Patterns Are Good For Managers
Patterns Are Good For ManagersPatterns Are Good For Managers
Patterns Are Good For Managers
 
決済サービスのSpring Bootのバージョンを2系に上げた話
決済サービスのSpring Bootのバージョンを2系に上げた話決済サービスのSpring Bootのバージョンを2系に上げた話
決済サービスのSpring Bootのバージョンを2系に上げた話
 
Comparing Native Java REST API Frameworks - Devoxx France 2022
Comparing Native Java REST API Frameworks - Devoxx France 2022Comparing Native Java REST API Frameworks - Devoxx France 2022
Comparing Native Java REST API Frameworks - Devoxx France 2022
 
Advanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap IsAdvanced Gadget And Ui Development Using Googles Ajax Ap Is
Advanced Gadget And Ui Development Using Googles Ajax Ap Is
 
Automating Hybrid Applications with Appium
Automating Hybrid Applications with AppiumAutomating Hybrid Applications with Appium
Automating Hybrid Applications with Appium
 
Google AJAX APIs
Google  AJAX APIsGoogle  AJAX APIs
Google AJAX APIs
 

Plus de Yu-Wei Chuang

Android N multi window
Android N multi windowAndroid N multi window
Android N multi windowYu-Wei Chuang
 
About Mobile Web Development Thing
About Mobile Web Development ThingAbout Mobile Web Development Thing
About Mobile Web Development ThingYu-Wei Chuang
 
Mojito 開發 mobile web 實戰經驗談
Mojito 開發 mobile web 實戰經驗談Mojito 開發 mobile web 實戰經驗談
Mojito 開發 mobile web 實戰經驗談Yu-Wei Chuang
 
Cocktails – Shaken, Not Stirred @osdc.tw
Cocktails – Shaken, Not Stirred @osdc.twCocktails – Shaken, Not Stirred @osdc.tw
Cocktails – Shaken, Not Stirred @osdc.twYu-Wei Chuang
 
Happy facebook developer
Happy facebook developerHappy facebook developer
Happy facebook developerYu-Wei Chuang
 

Plus de Yu-Wei Chuang (8)

Android N multi window
Android N multi windowAndroid N multi window
Android N multi window
 
About Mobile Web Development Thing
About Mobile Web Development ThingAbout Mobile Web Development Thing
About Mobile Web Development Thing
 
Ff os app demo
Ff os app demoFf os app demo
Ff os app demo
 
Mojito 開發 mobile web 實戰經驗談
Mojito 開發 mobile web 實戰經驗談Mojito 開發 mobile web 實戰經驗談
Mojito 開發 mobile web 實戰經驗談
 
Mojito@nodejstw
Mojito@nodejstwMojito@nodejstw
Mojito@nodejstw
 
Cocktails – Shaken, Not Stirred @osdc.tw
Cocktails – Shaken, Not Stirred @osdc.twCocktails – Shaken, Not Stirred @osdc.tw
Cocktails – Shaken, Not Stirred @osdc.tw
 
Happy facebook developer
Happy facebook developerHappy facebook developer
Happy facebook developer
 
Google Ajax APIs
Google Ajax APIsGoogle Ajax APIs
Google Ajax APIs
 

Dernier

Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...
Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...
Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...Erbil Polytechnic University
 
Immutable Image-Based Operating Systems - EW2024.pdf
Immutable Image-Based Operating Systems - EW2024.pdfImmutable Image-Based Operating Systems - EW2024.pdf
Immutable Image-Based Operating Systems - EW2024.pdfDrew Moseley
 
Engineering Drawing section of solid
Engineering Drawing     section of solidEngineering Drawing     section of solid
Engineering Drawing section of solidnamansinghjarodiya
 
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdfDEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdfAkritiPradhan2
 
Turn leadership mistakes into a better future.pptx
Turn leadership mistakes into a better future.pptxTurn leadership mistakes into a better future.pptx
Turn leadership mistakes into a better future.pptxStephen Sitton
 
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMSHigh Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMSsandhya757531
 
11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdf11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdfHafizMudaserAhmad
 
2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.
2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.
2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.elesangwon
 
Ch10-Global Supply Chain - Cadena de Suministro.pdf
Ch10-Global Supply Chain - Cadena de Suministro.pdfCh10-Global Supply Chain - Cadena de Suministro.pdf
Ch10-Global Supply Chain - Cadena de Suministro.pdfChristianCDAM
 
Input Output Management in Operating System
Input Output Management in Operating SystemInput Output Management in Operating System
Input Output Management in Operating SystemRashmi Bhat
 
Prach: A Feature-Rich Platform Empowering the Autism Community
Prach: A Feature-Rich Platform Empowering the Autism CommunityPrach: A Feature-Rich Platform Empowering the Autism Community
Prach: A Feature-Rich Platform Empowering the Autism Communityprachaibot
 
Novel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending ActuatorsNovel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending ActuatorsResearcher Researcher
 
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork
 
Energy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptxEnergy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptxsiddharthjain2303
 
Robotics Group 10 (Control Schemes) cse.pdf
Robotics Group 10  (Control Schemes) cse.pdfRobotics Group 10  (Control Schemes) cse.pdf
Robotics Group 10 (Control Schemes) cse.pdfsahilsajad201
 
signals in triangulation .. ...Surveying
signals in triangulation .. ...Surveyingsignals in triangulation .. ...Surveying
signals in triangulation .. ...Surveyingsapna80328
 
Artificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewArtificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewsandhya757531
 
System Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingSystem Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingBootNeck1
 
Cost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based questionCost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based questionSneha Padhiar
 
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTIONTHE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTIONjhunlian
 

Dernier (20)

Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...
Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...
Comparative study of High-rise Building Using ETABS,SAP200 and SAFE., SAFE an...
 
Immutable Image-Based Operating Systems - EW2024.pdf
Immutable Image-Based Operating Systems - EW2024.pdfImmutable Image-Based Operating Systems - EW2024.pdf
Immutable Image-Based Operating Systems - EW2024.pdf
 
Engineering Drawing section of solid
Engineering Drawing     section of solidEngineering Drawing     section of solid
Engineering Drawing section of solid
 
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdfDEVICE DRIVERS AND INTERRUPTS  SERVICE MECHANISM.pdf
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM.pdf
 
Turn leadership mistakes into a better future.pptx
Turn leadership mistakes into a better future.pptxTurn leadership mistakes into a better future.pptx
Turn leadership mistakes into a better future.pptx
 
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMSHigh Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
High Voltage Engineering- OVER VOLTAGES IN ELECTRICAL POWER SYSTEMS
 
11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdf11. Properties of Liquid Fuels in Energy Engineering.pdf
11. Properties of Liquid Fuels in Energy Engineering.pdf
 
2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.
2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.
2022 AWS DNA Hackathon 장애 대응 솔루션 jarvis.
 
Ch10-Global Supply Chain - Cadena de Suministro.pdf
Ch10-Global Supply Chain - Cadena de Suministro.pdfCh10-Global Supply Chain - Cadena de Suministro.pdf
Ch10-Global Supply Chain - Cadena de Suministro.pdf
 
Input Output Management in Operating System
Input Output Management in Operating SystemInput Output Management in Operating System
Input Output Management in Operating System
 
Prach: A Feature-Rich Platform Empowering the Autism Community
Prach: A Feature-Rich Platform Empowering the Autism CommunityPrach: A Feature-Rich Platform Empowering the Autism Community
Prach: A Feature-Rich Platform Empowering the Autism Community
 
Novel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending ActuatorsNovel 3D-Printed Soft Linear and Bending Actuators
Novel 3D-Printed Soft Linear and Bending Actuators
 
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
Stork Webinar | APM Transformational planning, Tool Selection & Performance T...
 
Energy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptxEnergy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptx
 
Robotics Group 10 (Control Schemes) cse.pdf
Robotics Group 10  (Control Schemes) cse.pdfRobotics Group 10  (Control Schemes) cse.pdf
Robotics Group 10 (Control Schemes) cse.pdf
 
signals in triangulation .. ...Surveying
signals in triangulation .. ...Surveyingsignals in triangulation .. ...Surveying
signals in triangulation .. ...Surveying
 
Artificial Intelligence in Power System overview
Artificial Intelligence in Power System overviewArtificial Intelligence in Power System overview
Artificial Intelligence in Power System overview
 
System Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingSystem Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event Scheduling
 
Cost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based questionCost estimation approach: FP to COCOMO scenario based question
Cost estimation approach: FP to COCOMO scenario based question
 
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTIONTHE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
THE SENDAI FRAMEWORK FOR DISASTER RISK REDUCTION
 

When Web meet Native App

  • 1. CONFIDENTIAL & PROPRIETARY Page  Title SUBTITLE 1 When     Web   meet     Na6ve  App Eric  Chuang 當網⾴頁遇上原⽣生App
  • 2. CONFIDENTIAL & PROPRIETARY When  Web  meet  Na6ve  App Yahoo  Taiwan  Mobile  Team   Eric  Chuang 2
  • 3. CONFIDENTIAL & PROPRIETARY About  Me • Eric  Chuang  (ddsakura)   • WebConf  2012  Speaker   • Yahoo  Lead  Engineer 3 • Full  Stack  Engineer  ?   – Developed  Yahoo  E-­‐Commerce  Mobile  Web   – Developed  Yahoo  E-­‐Commerce  超級商城  iPhone  App   – Developed  Yahoo  E-­‐Commerce  拍賣  Android  App
  • 6. Web  in  Auc6on  Android  App
  • 7. CONFIDENTIAL & PROPRIETARY What  is  Webview • A  View  that  displays  web  pages.   • Android   – Since  API  1   • iOS   – UIWebView   – MKWebView 7
  • 8. CONFIDENTIAL & PROPRIETARY 曾經我以為 Android  Webview  >  iOS  UIWebview                                                                                                (can  not  use  Nitro  JavaScript  Engine  ) 8 Android  Webview  ==  Android  Browser
  • 10. CONFIDENTIAL & PROPRIETARY hWp://beta.html5test.com/
  • 11. CONFIDENTIAL & PROPRIETARY 結果… 11 Android  Webview  !=  Android  Browser Android  Webview  v.s.  iOS  UIWebview/MKWebview
  • 13. CONFIDENTIAL & PROPRIETARY Android  Webview  version • Android  4.4   – Chromium  30 13 • Android  4.4.3   – Chromium  33 • Android  5.0   – Chromium  37 • And  in  google  play   – hWps://play.google.com/store/apps/details?id=com.google.android.webview  
  • 15. CONFIDENTIAL & PROPRIETARY Android  Webview  version • Android  before  4.4   – Old  Webview   – Vendor  may  “improve”  their  webview   – ref:  hWp://slides.com/html5test/the-­‐android-­‐browser#/12 15
  • 16. CONFIDENTIAL & PROPRIETARY SO  WE  NO  LONGER  HAVE   ONE  WEBVIEW  FOR   EACH  ANDROID  VERSION BUT 16 ONE  FOR  SAMSUNG, AND  ONE  FOR  HTC, AND  ONE  FOR  ...
  • 17. CONFIDENTIAL & PROPRIETARY Let’s  start  webview • We  need  permission 17 <uses-­‐permission  android:name="android.permission.INTERNET"  /> • Basic  usage WebView  mWebview  =  new  WebView(this);   mWebview.loadUrl(“file:///android_asset/www/index.html”);   mWebview.loadUrl(“hWp://tw.yahoo.com/“);   String  summary  =  “<html><body>Hello  World</body></html>”;   mWebview.loadData(summary,  "text/html",  null);  
  • 18. CONFIDENTIAL & PROPRIETARY Local  Assets • file:///android_asset/   – The  assets  directory  of  an  Android  app  is  located  at                                                         src/main/assets  inside  your  Android  Studio  project. 18
  • 19. CONFIDENTIAL & PROPRIETARY How  about  JavaScript • WebViews  don't  allow  JavaScript  by  default. 19 //  Enable  JavascriptWebSepngs     webSepngs  =  mWebView.getSepngs();   webSepngs.setJavaScriptEnabled(true);
  • 20. CONFIDENTIAL & PROPRIETARY Configure  webview • Websepngs   – setJavaScriptEnabled     • The  default  is  false.   – setGeoloca6onEnabled     • The  default  is  true.     • ACCESS_COARSE_LOCATION,  ACCESS_FINE_LOCATION   – setBuiltInZoomControls     • The  default  is  false.     – setDomStorageEnabled     • The  default  value  is  false. 20hWp://developer.android.com/reference/android/webkit/WebSepngs.html
  • 21. CONFIDENTIAL & PROPRIETARY Configure  webview  cont. • UserAgent   – getUserAgentString   – setUserAgentString 21 Mozilla/5.0  (Linux;  U;  Android  4.1.1;  en-­‐gb;  Build/KLP)  AppleWebKit/534.30  (KHTML,  like  Gecko)  Version/4.0  Safari/534.30 Mozilla/5.0  (Linux;  Android  4.4;  Nexus  5  Build/_BuildID_)  AppleWebKit/537.36  (KHTML,  like  Gecko)  Version/4.0  Chrome/ 30.0.0.0  Mobile  Safari/537.36 hWps://developer.chrome.com/mul6device/user-­‐agent
  • 23. CONFIDENTIAL & PROPRIETARY WebViewClient • Instance  of  WebViewClient  that  is  the  client  callback.   • It  will  be  called  when  things  happen  that  impact  the   rendering  of  the  content,   • Func6ons   – onLoadResource   – onPageStart   – onPageFinish   – onReceiveError   – shouldInterceptRequest   23 hWp://developer.android.com/reference/android/webkit/WebViewClient.html
  • 24. CONFIDENTIAL & PROPRIETARY WebChromeClient • Instance  of  WebChromeClient  for  handling  all  chrome   func6ons.   • This  class  is  called  when  something  that  might  impact  a   browser  UI  happens,  for  instance,  progress  updates  and   JavaScript  alerts  are  sent  here     • Func6ons   – onCloseWindow   – onCreateWindow   – onJsAlert   – onJsPrompt   – onJsConfirm   24 hWp://developer.android.com/reference/android/webkit/WebChromeClient.html
  • 25. CONFIDENTIAL & PROPRIETARY Example  between  WebViewClient  and  WebChromeClient 25
  • 26. CONFIDENTIAL & PROPRIETARY Handling  Links • Default  behavior:  load  that  URL  of  the  link  in  the  default   Android  browser.   26 Intercept  the  url  !!
  • 27. CONFIDENTIAL & PROPRIETARY Intercep6ng  WebView  HTTP  Requests • public  boolean  shouldOverrideUrlLoading  (WebView  view,   String  url)   – Give  the  host  applica6on  a  chance  to  take  over  the  control  when  a   new  url  is  about  to  be  loaded  in  the  current  WebView.   27
  • 28. CONFIDENTIAL & PROPRIETARY Intercep6ng  example  1 28 if  (path.contains(ECWebView.WEB_URL_ECAUCTION_TYPE_PRODUCT_ITEM))  {                          showItemPage(url);  //  call  na6ve  component                          return  true;   }   if  (path.contains(ECWebView.WEB_URL_ECAUCTION_TYPE_SELLER_BOOTH))  {                          showSellerBooth(url);  //  call  na6ve  component                          return  true;   }
  • 29. CONFIDENTIAL & PROPRIETARY Intercep6ng  example  2 29 if (whiteList.indexOf(host) != -1) { toggleLoadingUI(true); return false; }
  • 30. CONFIDENTIAL & PROPRIETARY From  JavaScript  to  Java  -­‐  Android  Part 30 public  class  WebAppInterface  {          Context  mContext;          /**  Instan6ate  the  interface  and  set  the  context  */          WebAppInterface(Context  c)  {                  mContext  =  c;          }          /**  Show  a  toast  from  the  web  page  */          @JavascriptInterface          public  void  showToast(String  toast)  {                  Toast.makeText(mContext,  toast,  Toast.LENGTH_SHORT).show();          }   } webView.addJavascriptInterface(new  WebAppInterface(this),  "Android");
  • 31. CONFIDENTIAL & PROPRIETARY From  JavaScript  to  Java  -­‐  HTML  Part 31 <input  type="buWon"  value="Say  hello"  onClick="showAndroidToast('Hello  Android!')"  />   <script  type="text/javascript">          func6on  showAndroidToast(toast)  {                  Android.showToast(toast);          }   </script>
  • 32. CONFIDENTIAL & PROPRIETARY From  Java  to  JavaScript 32 mWebView.loadUrl("javascript:window.cartList.closeOverlay()");
  • 33. CONFIDENTIAL & PROPRIETARY Naviga6ng  web  page  history 33 @Override   public  boolean  onKeyDown(int  keyCode,  KeyEvent  event)  {          //  Check  if  the  key  event  was  the  Back  buWon  and  if  there's  history          if  ((keyCode  ==  KeyEvent.KEYCODE_BACK)  &&  myWebView.canGoBack())  {                  myWebView.goBack();                  return  true;          }          //  If  it  wasn't  the  Back  key  or  there's  no  web  page  history,  bubble  up  to  the  default          //  system  behavior  (probably  exit  the  ac6vity)          return  super.onKeyDown(keyCode,  event);   }
  • 34. CONFIDENTIAL & PROPRIETARY Cache  Web  Resources 34 @Override   public  WebResourceResponse  shouldInterceptRequest(WebView  view,  String  url)  {          if(url.startsWith("hWp://mydomain.com/ar6cle/")  {                  String  cacheFileName  =  url.substring(url.lastIndexOf("/"),  url.length());                  this.urlCache.register(url,  cacheFileName,                                  "text/html",  "UTF-­‐8",  60  *  UrlCache.ONE_MINUTE);          }          return  this.urlCache.load(url);   }  
  • 35. CONFIDENTIAL & PROPRIETARY Android  Lollipop • Mixed  content  issue 35                if  (android.os.Build.VERSION.SDK_INT  >=  21)  {                          webSepngs.setMixedContentMode(WebSe<ngs.MIXED_CONTENT_ALWAYS_ALLOW);                  }
  • 36. CONFIDENTIAL & PROPRIETARY Cookie • CookieManager   – Manages  the  cookies  used  by  an  applica6on's  WebView  instances.   • setCookie(String  url,  String  value)   • getCookie(url)   • CookieSyncManager   – This  class  was  deprecated  in  API  level  21.  The  WebView  now   automa6cally  syncs  cookies  as  necessary.  You  no  longer  need  to   create  or  use  the  CookieSyncManager.  To  manually  force  a  sync  you   can  use  the  CookieManager  method  flush()  which  is  a  synchronous   replacement  for  sync().   36
  • 37. CONFIDENTIAL & PROPRIETARY Handle  HWp  Error 37                        @Override                          public  void  onReceivedError(WebView  view,  int  errorCode,  String  descrip6on,  String   failingUrl)  {                                  …                          }                          @Override                          public  void  onReceivedSslError(WebView  view,  SslErrorHandler  handler,  SslError  error)  {                                  handler.proceed();  //  Ignore  SSL  cer6ficate  errors                          }
  • 38. CONFIDENTIAL & PROPRIETARY Handle  HWp  Error  bug • onReceivedError  STILL  does  not  receive  HTTP  Errors   – hWps://code.google.com/p/android/issues/detail?id=82069 38 @Override public void onPageFinished(WebView view, String url) { if (WEBPAGE_ERROR_HTML_TITLE.indexOf(mWebContentTitle) != -1) { mListener.onPageReceivedError(view, WEBPAGE_ERROR_CODE, mWebContentTitle, url); } }
  • 39. CONFIDENTIAL & PROPRIETARY Debugging  webview • Requirements   – Chrome  32  or  later  installed  on  your  development  machine.   – A  USB  cable  to  connect  your  Android  device.   – For  app  debugging:  Android  4.4+  and  a  WebView  configured  for   debugging. 39  if  (Build.VERSION.SDK_INT  >=  Build.VERSION_CODES.KITKAT)  {              WebView.setWebContentsDebuggingEnabled(true);      }
  • 40. CONFIDENTIAL & PROPRIETARY Debugging  webview  cont. • The  chrome://inspect  page  displays  a  list  of  debug-­‐ enabled  WebViews  on  your  device.   • To  start  debugging,  click  inspect  below  the  WebView  you   want  to  debug.     • As  of  KitKat  4.4.3,  screencast  is  available  for  both  browser   tabs  and  Android  WebViews. 40
  • 41. CONFIDENTIAL & PROPRIETARY Tes6ng  with  Webview • Robo6um   – hWps://code.google.com/p/robo6um/ 41                //  Type  in  text  box                  WebElement  txtSearch  =  solo.getWebElement(By.name("q"),  0);                  txtSearch.setTextContent("Hello");                  //  click  buWon                  WebElement  btnSearch  =  (WebElement)  solo.getWebElement(By.name("btnG"),  0);                  solo.clickOnWebElement(btnSearch);
  • 42. CONFIDENTIAL & PROPRIETARY Project  that  Improve  Webview • Crosswalk   – hWps://crosswalk-­‐project.org/   – Develop  around  device  fragmenta6on   – Provide  a  feature  rich  experience                                                                                                                           all  on  Android  4.x  devices   – Easily  debug  with  Chrome  DevTools   – Improve  the  performance  of                                                                                                                                       HTML,  CSS,  and  JavaScript 42
  • 43. CONFIDENTIAL & PROPRIETARY Conclusion • 這不是⾮非⿊黑即⽩白的世界   – Web  跟  Na6ve  App  亦然   • 讓  Web  和  Na6ve  App  共舞   – 提供使⽤用者最好的體驗 43
  • 44. CONFIDENTIAL & PROPRIETARY Thank  you 44 Eric  Chuang hKp://bit.ly/1JkyR1W