分手之後,過得更好的兩個人

在網頁專案中常會碰到在介面上需透過資料庫提供的資料來進行呈現,這樣的介面在程式開發時通常會透過兩種方法進行, 以下針對上述的兩種方法進行一些工作方式說明與做法上的分享 。

傳統的開發模式


前、後端人員會先針對頁面設計進行可行性的討論,在前端在頁面製作完成後,逐步Release出來給後端工程師,讓後端工程師根據已經製作好的頁面進行施工,他們會在版面中加入後端程式(ASP、PHP、JSP…等),以此方式進行介面設計,最後會在後端工程師處完稿。

上圖的動態網頁版面是指將頁面串接上資料庫(Dynamic),透過資料庫的資料來進行呈現,也就是資料是”活的”,通常前端工程師會在版面中先放入一些假資料,讓後端工程師了解呈現風格,此處的動態不是指動畫,任何在頁面上的互動或動畫,應該是由前端工程師來完成。

前、後端分離


理想的做法是後端人員幾乎不用了解前端介面想如何呈現,所有API為前端人員依據頁面開需求給後端,例如產品目錄頁需要一隻API可以呈現:

  • 商品名稱
  • 價格
  • 顏色
  • 尺寸
  • 依據前端傳入的參數來定義
    • 一次給幾筆
    • 從第幾筆開始給
  • 可透過什麼條件進行篩選

以此方式進行介面設計,最後會在前端開發者處完稿。

前、後端分手後的好處

前、後端合併是傳統的合作模式,當時前端沒有好的方法可以呼叫後端API,所以所有的串接都必須由後端工程師進行協助,而自從前端程式可以透過AJAX的方式呼叫後端程式後,前、後端分離的做法就被廣為應用,他也帶來了以下的優點:

1. 權責區分明確

前、後端分離讓人員可以各自負責自己擅長的部份,前端工程師不會需要碰到伺服器端的程式,後端工程師也不會碰到前端的動畫或版面程式,能將權責清楚的區分出來,不會到時候發生網頁跑版、動畫出問題,但不清楚到底是誰動到了不該動的東西。

所以前、後端分離也就是權責上也更能夠釐清,別小看這個部分,因為這不僅僅讓雙方人員在專案開發上目標更為明確,也能夠讓專案管理變得更輕鬆。

2. 跨平台的API應用

專案中的應用平台有時不僅僅是Web,若有其他平台也有後端的需求,之前開發出來的API規格依然可以生效,就算有修改,也能依照相同的精神調整,對於後端工程師來說工作可以更單純一些。

3. 平行的開工時間

在看到ART Design所設計出來的頁面後,雙方可以迅速討論並且同時開工,不像傳統的專案,後端工程師需要等前端頁面完成後才可以施作,更能夠提升專案上的製作行程。

You may also like...

34,318 Responses

  1. Тут можно преобрести купить сейф под ружье оружейный шкаф цена

  2. CurtisCem表示:

    buy Gabapentin GabaPharm GabaPharm buy Gabapentin GabaPharm

  3. сколько стоит купить франшизу сколько стоит купить франшизу .

  4. франшиза в россии https://franshizy19.ru .

  5. pupis表示:

    Мобильные ставки доступны каждому — просто скачайте приложение БК и начните выигрывать прямо сейчас

  6. DennishIp表示:

    furosemide furpharm.com: furosemide fur pharm – furosemide fur pharm

  7. бизнес по франшизе бизнес по франшизе .

  8. Тут можно преобрести ящик для оружия купить сейф для охотничьего ружья

  9. вывод из запоя в стационаре ростов-на-дону вывод из запоя в стационаре ростов-на-дону .

  10. Тут можно преобрести пожаростойкие сейфы сейф огнеупорный купить

  11. LloydNoice表示:

    https://gabapharm.com/# cheapest Gabapentin GabaPharm

  12. Briankib表示:

    Joseph R. Biden Jr. promised to be the most pro-labor president in history. He embraced unions more overtly than his predecessors in either party, and filled his administration with union supporters.
    [url=https://kraken2trfqodidvlh4aa337cpzfrhdlfldhve5nf77instad.com]kraken4qzqnoi7ogpzpzwrxk7mw53n5i56loydwiyonu4owxsh4g67yd.onion[/url]
    Labor seemed to respond accordingly. Filings for unionization elections spiked to their highest level in a decade, as did union victories. There were breakthroughs at companies like Starbucks and Amazon, and unions prevailed in organizing a major foreign auto plant in the South. A United Automobile Workers walkout yielded substantial contract gains — and images of Mr. Biden joining a picket line.

    As Donald J. Trump prepares to retake the White House, labor experts expect the legal landscape for labor to turn sharply in another direction.

    Based on Mr. Trump’s first term and his comments during the campaign — including his praise for Tesla’s chief executive, Elon Musk, for what he said was Mr. Musk’s willingness to fire striking workers — these experts say the new administration is likely to bring fewer challenges to employers who fight unions.

    kraken6gf6o4rxewycqwjgfchzgxyfeoj5xafqbfm4vgvyaig2vmxvyd.onion
    https://kraken3yvbvzmhytnrnuhsy772i6dfobofu652e27f5hx6y5cpj7rgydonion.net

  13. Michaelwhaws表示:

    King Charles has led the nation in two minutes of silence in remembrance of men and women who lost their lives serving in the two world wars or other conflicts.
    [url=https://kraken6gf6o4rxewycqwjgfchzgxyfeoj5xafqbfm4vgvyaig2vmxvyd-onion.net]kraken6gf6o4rxewycqwjgfchzgxyfeoj5xafqbfm4vgvyaig2vmxvyd[/url]
    Tens of thousands of veterans and civilians joined the King in paying their respects to the fallen at the annual National Service of Remembrance ceremony at the Cenotaph in central London.

    The King was joined by other members of the Royal Family, including the Prince and Princess of Wales, and political leaders.

    Events to mark Remembrance Sunday – observed on the closest Sunday to Armistice Day – are taking place around the country.

    The King laid the first wreath on behalf of the nation. Dressed in the Royal Navy uniform of the Admiral of the Fleet, he saluted after stepping back from the Cenotaph.

    The King was followed by Queen Camilla’s equerry, Major Ollie Plunket, laying a wreath on her behalf as she is currently recovering from a chest infection.

    Prince William, Prince Edward and Princess Anne followed, then Prime Minister Sir Keir Starmer and the country’s other political leaders.

    кракен магазин
    https://kraken6gf6o4rxewycqwjgfchzgxyfeoj5xafqbfm4vgvyaig2vmxvyd-onion.com

  14. Raymondraige表示:

    Anna Moneymaker/Getty Images
    [url=https://2krkn-mp.org]kra16.cc[/url]
    Trump improved on GOP margins nearly everywhere and delivered on his promise to win over more non-White voters
    Live Updates Here’s where things stand in the House, as GOP hopes to complete a sweep in Washington
    Still-stunned Democrats begin to squint toward their future
    We asked Americans what they’d heard about Trump and Harris throughout the campaign. Here’s what they told us
    Supreme Court Justice Sotomayor to stay at job as some call for her to step down
    January 6 rioters and judges digest the impact of Trump’s victory
    kra16.cc
    https://kra8gl.cc

  15. RobertHam表示:

    http://gabapharm.com/# Buy gabapentin for humans

發佈留言

發佈留言必須填寫的電子郵件地址不會公開。