SpringBoot으로 웹 출시까지 #4

springboot logo

4. thymeleaf를 이용해 레이아웃 만들기

1 myhome 만들기

https://start.spring.io/

 

project : maven

springboot :  최대한 낮은 버전 / SNAPSHOT X로 선택

group : godcoder

artifact, name : myhome

java: 8

dependencies : Thymeleaf / Spring Web / Spring Boot DevTools / Lombok

2 IntelliJ와 git 연동하기

https://github.com/

깃허브 계정이 없으신분들은 회원가입을 진행합니다.

그 뒤 강의 내용대로 진행하시면 됩니다.

저는 이번 클론 코딩을 진행하는 모든 코드를 한 번에 관리하기 위해 강의와 다르게 연동하였습니다.

git repository 생성 및 로컬 폴더 연결

을 누르시면 모든 프로젝트를 하나의 리포지토리로 관리 하실 수 있습니다.

3 bootstrap 적용

부트스트랩 스타터 탬플릿 적용

https://getbootstrap.kr/docs/5.0/getting-started/introduction/

– 강의 시점과 시간이 달라 버전이 업그레이드 되었습니다.

    코드가 달라지고, 명령어가 수정되었습니다.

    최대한 유사한 코드를 사용해서 작성했습니다.

<!doctype html>
<html lang="en">
  <head>
    <!-- Required meta tags -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <!-- Bootstrap CSS -->
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">

    <title>Hello, world!</title>
  </head>
  <body>
    <h1>Hello, world!</h1>

    <!-- Optional JavaScript; choose one of the two! -->

    <!-- Option 1: Bootstrap Bundle with Popper -->
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script>

    <!-- Option 2: Separate Popper and Bootstrap JS -->
    <!--
    <script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js" integrity="sha384-IQsoLXl5PILFhosVNubq5LC7Qb9DXgDA9i+tQ8Zj3iwWAwPtgFTxbJ8NT4GN1R8p" crossorigin="anonymous"></script>
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.min.js" integrity="sha384-cVKIPhGWiC2Al4u+LWgxfKTRIcfu0JTxR+EQDz/bgldoEyl4H0zUF0QKbrJ0EcQF" crossorigin="anonymous"></script>
    -->
  </body>
</html>

Visual Studio Code 연결

컴퓨터에 자동 설치된 비주얼스튜디오를 실행시켜 프로젝트 파일(myhome – main – resources)을 열어줍니다.

template 폴더 아래 “index.html” 파일을 만들고 복사한 내용을 붙여넣습니다.

<html lang=“en”> -> <html>으로 수정합니다.

[intelliJ] HomeController 만들기

myhome 아래 “controller” 폴더를 생성하고,  “HomeController” 클래스를 작성합니다.

package com.godcoder.myhome.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;

@Controller
public class HomeController {
@GetMapping
public String index(){
return "index";
}
}

[VSCode]starter-template.css 작성

myhome – src – main – resources – static 아래 “starter-template.css” 파일을 생성합니다.

body {
padding-top: 5rem;
}
.starter-template {
padding: 3rem 1.5rem;
text-align: center;
}

“SpringBoot으로 웹 출시까지 #4”의 65,969개의 댓글

  1. можно ли купить трамадол без рецепта купить гашиш закладки Мефедрон, кокаин, бошки, гашиш наркошоп купить можно купить таблетки трамадол купить марихуану мефедрон
    где купить наркотики купить меф тг сайт закладок наркотикиhttps://genicheskkupit.xyz купить соли мефедрон где можно купить трамадол

  2. В этой статье обсуждаются актуальные медицинские вопросы, которые волнуют общество. Мы обращаем внимание на проблемы, касающиеся здравоохранения и лечения, а также на новшества в области медицины. Читатели будут осведомлены о последних событиях и смогут следить за тенденциями в медицине.
    Кликни, не пожалеешь – [url=https://homerenow.ru/pages/narkologicheskaya-klinika-v-ekaterinburge/]наркологическая клиника екатеринбург[/url]

  3. В данной статье мы поговорим о будущем медицины, акцентируя внимание на прорывных разработках и их потенциале. Читатель узнает о новых подходах к лечению, роли искусственного интеллекта и возможностях персонализированной медицины.
    Погрузиться в детали – [url=https://narcologiya.info/pohmele/kak-vylechit-pokhmele-doma.html]центр наркологии[/url]

  4. Comprehending the guidelines of your top gaming site is an pivotal step for all player [url=https://spino-gambinogame.ca/terms-and-conditions]spinogambino[/url] . When you access the main webpage at spino-gambinogame.ca/terms-and-conditions, you are engaging with the basic contract that governs your experience on the service. Reviewing these provisions is not merely a formality; it is a necessary procedure for everybody striving to interact with the utilities delivered by spinogambino in a protected and informed manner.

    The terms and conditions page functions as a comprehensive legal document connecting you and the company. It highlights vital data concerning account enrollment, identity validation, and the mindful use of services. By visiting the site, you agree to adhere to these protocols, which are designed to provide fair gaming and clarity for every user. For illustration, the paper specifies the requirements for controlling your balance, executing withdrawals, and joining marketing deals. Grasping these specific details assists players evade frequent mistakes and misunderstandings, securing a smooth journey while browsing the diverse games supplied by spino gambino.

    Additionally, the statutory section offers transparency on security protocols and the protection of your private details. It explains the way your content is managed and what steps are in effect to maintain a safe atmosphere for every users. Regardless of whether you are interested in promotional playthrough requirements or the policies directing membership cancellation, the terms and conditions page is your primary source for reliable details.

    We highly recommend that every player take a several time to read over this documentation diligently. Being acquainted with the principles enables you maintain full oversight of your play sessions and ensures that you continue in compliance with the hub’s norms. By prioritizing transparency and staying educated, you can access the full selection of tools accessible on the site with certainty. Always recall that staying informed regarding the rules is the top approach to secure your assets and make the most of your hours invested exploring the wide opportunities provided by spinogambino.

  5. chickenroad-Mypex

    Chicken Run se convierte en un entretimiento multijugador que ha crecido en los recientes meses, en particular entre los aficionados de los entretimientos virtuales de movimiento y los modas populares [url=https://chickenroad-es-50.onrender.com]Chicken Road Opiniones Español[/url] .

    Si buscas necesitando opiniones verídicas sobre este producto, se vuelve clave examinar tanto sus características buenos como sus posibles problemas para evaluar si merece la inversión experimentarlo. En este artículo, os ofrecemos un reporte derivado en las opiniones frecuentes que se encuentran en comunidades como GruposGamers, además como en experiencias compartidas por usuarios en español.

    Una de las primeras notas que resaltan los aficionados se trata de la elegancia del entretimiento. Chicken Run es ideal para la mayoría usuario, ya que su sistema resulta intuitiva: eludir obstáculos mientras navegas por una carretera virtual. Esto a este entretenimiento transforma ideal para quienes buscan un juego inmediato, sobre todo en dispositivos móviles. Muchos usuarios destacan que no exige conocimientos profesionales de control, lo que a este juego transforma en una elección entretenida para ocupar el momento vacío.

    Sin la realidad no siempre resultan a ventajas destacados. Algunas críticas en comunidades como ForosAutos destacan que el juego puede resultar repetitivo con el tiempo, sobre todo si se juega de forma constante. La ausencia de elementos novedoso y la repetición de niveles similares son puntos que generan aburrimiento en algunos jugadores. Por otro lado, hay críticas sobre la promociones intrusiva que se muestra en la versión gratuita, lo que puede convertirse en incómodo si no se te encuentras motivado a pagar por la versión pro.

    Otro factor a evaluar resulta la estabilidad del entretimiento. Aunque Poultry Race se accede desde todo navegador, algunos aficionados han denunciado errores de conexión o baja velocidad al usar, en particular en servidores ajenos como Hosting. Esto puede provenir de la técnica técnica del plataforma, que no todavía promete una sesión smooth. Si deseas un entretimiento sin fallos y sin problemas, es ideal revisar las reseñas actuales antes de invertir en él.

    En cuanto a la gente, Poultry Road tiene con un núcleo de jugadores comprometidos en plataformas sociales y foros, donde se comparten tips y sugerencias para potenciar el resultado. Esto puede convertirse en beneficioso para quienes quieren optimizar su sesión, pero también hay que evaluar en cuenta que, como en todo juego en línea, puede haber competencia o desánimo si no se supera atravesar determinados etapas.

    Si te qué es exactamente Chicken Run, se trata un entretimiento de movimiento variante *”chicken run”*, donde el propósito resulta sobrevivir el mayor período posible eludiendo colisiones. Su éxito depende en su facilidad y en la sensación de adrenalina que proporciona. Aunque no se considera un entretimiento técnico, su atracción resulta verdadera para muchos, sobre todo por los marcadores individuales y las competencias con diversos jugadores.

    En resumen, las críticas sobre Poultry Run son diversas, pero la mayoría se ponen de acuerdo en que es un juego entretenido para instantes de ocio. Si buscas alguien sencillo de usar y con un rasgo desafiante, puede resultar una ideal alternativa, siempre estés dispuesto para enfrentar sus restricciones técnicas y la eventual monotonía. Antes de probarlo, lee las reseñas más en comunidades como GruposGamers o en sitios de entretenimiento para confirmar que se adapta a lo que deseas.

  6. spinogambino-Jeaduat

    Η πολιτική cookies αποτελεί το θεμελιώδες κομμάτι της εχεμύθειας και την προστασίας σε κάθε τρέχουσα πλατφόρμα τυχερών παιχνιδιών [url=https://spinogambino-casino.com.gr/cookie-policy]spino gambino[/url] . Πάνω στην ιστοσελίδα spinogambino-casino.com.gr, η προστασία των προσωπικών δεδομένων των μελών αποτελεί κορυφαία προτεραιότητα. Πατώντας τη σελίδα πολιτικής cookies του site, οι χρήστες έχουν τη δυνατότητα να ενημερωθούν αναλυτικά σχετικά με τον τρόπο με τον οποίο το Spino Gambino εκμεταλλεύεται αυτές τις μικρές μονάδες πληροφοριών για να βελτιώσει την εμπειρία πλοήγησης.

    Αυτά τα cookies στο spinogambino καλύπτουν πλήθος σκοπούς. Καταρχάς, εξασφαλίζουν την σωστή λειτουργία της πλατφόρμας, δίνοντας τη δυνατότητα στον χρήστη να μένει συνδεδεμένος και να απολαμβάνει τις υπηρεσίες απαλλαγμένες από καθυστερήσεις. Επιπλέον, επιστρατεύονται για την ανάλυση της επισκεψιμότητας, βοηθώντας το Spino Gambino να κατανοήσει τις τάσεις του κοινού του και να προσαρμόσει τις υπηρεσίες του στις ανάγκες των μελών. Υπάρχουν τα απαραίτητα cookies που παρουσιάζονται πάντα σε ισχύ, καθώς και cookies μετρήσεων ή προώθησης, στα οποία το καζίνο απαιτεί τη ρητή συγκατάθεση του μέλους.

    Αυτή η διαφάνεια στο spinogambino-casino.com.gr είναι έμπρακτη. Όλος ο παίκτης κατέχει τον πλήρη έλεγχο των παραμέτρων του προγράμματος περιήγησής του, φέρνοντας τη δυνατότητα να εγκρίνει, να μπλοκάρει ή να διαγράψει τα cookies διαρκώς. Η σελίδα της πολιτικής cookies δίνει όλες τις χρήσιμες πληροφορίες για τη χρόνο διατήρησης των αρχείων αυτών καθώς και τη αξιοποίηση αυτών από εξωτερικούς φορείς.

    Προτιμώντας το spinogambino για το παιχνίδι σας, εμπιστεύεστε μια πλατφόρμα που υπολογίζει την ιδιωτικότητά σας καθώς συμβαδίζει σύμφωνα με τους πιο σκληρούς κανόνες προστασίας δεδομένων. Η τακτική ενημέρωση της πολιτικής cookies διασφαλίζει ότι οι παίκτες ξέρουν πάντα πώς συλλέγονται καθώς και διαχειρίζονται τα δεδομένα τους. Για οποιαδήποτε προβληματισμό που αφορά τη επεξεργασία των cookies, η ομάδα εξυπηρέτησης του Spino Gambino στέκεται στη διάθεση των παικτών, προσφέροντας ένα έμπιστο, αξιόπιστο καθώς και ειδικό περιβάλλον παιχνιδιού για τους πάντες τους λάτρεις του καζίνο. Αυτή η ενδεδειγμένη ενημέρωση είναι το πρώτο στάδιο για μια προσεκτική και ευχάριστη διαδικτυακή εμπειρία.

  7. Мы рассмотрим современные вызовы здравоохранения и пути их решения с помощью технологий и научных исследований. В статье собраны данные о новых лекарствах, методах диагностики и системном подходе к улучшению здоровья населения.
    Смотри, что ещё есть – [url=https://otalkogolizma.ru/stati/chem-opasen-etizolam-v-rossii/]наркология клиника[/url]

  8. chicken-enfomia

    Should you are seeking for an engaging approach to test your luck and planning, the chicken road app has rapidly turned into a popular selection between handheld players [url=https://chicken-road-logincasino.com/app]chicken road app review[/url] . This hub delivers a singular playing journey that merges high-speed action along with the opportunity to win rewards. In this chicken road app review, we investigate why such a large number of clients are flocking to this interface to try their skills at the viral title. The center of the session is the chicken road game app, which centers on navigating obstacles to attain the target. Given its notoriety, the chicken road game app download procedure is straightforward, enabling players to setup the software on their devices and start gaming in under moments.

    A lot of interested players often ask if the chicken road app legit reputation is secure. When participating with any chicken road app casino, it is critical to maintain mindful betting. The chicken road gambling app provides a polished interface that makes it simple for users to track their advancement and control their sessions efficiently. As a modern chicken road betting app, it employs responsive inputs that keep the experience absorbing no matter if you are a novice or a veteran gamer.

    One motive for the expansion of the system is its standing as a possible chicken road earning app. Although no app guarantees reliable profits, the excitement of the features maintains the group lively and growing. Prior to you commence, ensure you have the genuine chicken road game gambling app loaded to ensure the optimal execution and security. By choosing the correct build, you secure a easy transition from getting the files to playing your opening turn. Whether you are drawn to the competitive nature of the software or just seeking a new method to kill the hours, this portable hub delivers a unique virtual environment. Always wager inside your limits and relish the fun benefit delivered by this trending application. As the platform continues to evolve, it remains a hub for those searching for a joyful and rapid mobile gaming adventure.

  9. Эта статья подробно расскажет о процессе выздоровления, который включает в себя эмоциональную, физическую и психологическую реабилитацию. Мы обсуждаем значимость поддержки и наличие профессиональных программ. Читатели узнают, как строить новую жизнь и не возвращаться к старым привычкам.
    Только факты! – [url=https://boilervdom.ru/zdorove/vyvesti-iz-zapoya-na-domu.html]вывод из запоя в клинике[/url]

댓글 달기

이메일 주소는 공개되지 않습니다.