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”의 20,094개의 댓글

  1. uma plataforma esta tem ganhado reconhecimento dentro do cenário das bets virtuais no Brasil, oferecendo diversas possibilidades que permitem quem procura entretenimento e, relaxamento pode um passo para uma uma confiável vivência confiável com prazerosa [url=https://cbet-5.onrender.com]Cbet Jogo[/url] .

    A plataforma digital Cbet Brasil é popular graças a seu sistema meio intuitivo e rápido entrada, possibilitando os jogadores apreciem dos atividades como roleta, jogos de azar e jogos esportivos de competições. Vários clientes nacionais se envolvido se sentiram interessado pelo universo do Cbet Plataforma, devido a a grande simplicidade e também a enorme variedade de disponíveis. Antes de então, é fundamental crítico checar se a plataforma se apresenta credível, notadamente no um no qual a reputação é vista como.

    Uma uma das principais mais recorrentes incertezas quando se trata do Cbet Casino é quando ele se revela efetivamente protegido para transações de valores. Redes confiáveis tendem a contarem com autorizações válidas com estratégias de proteção aos. Ao esse Cbet, é essencial verificar que se adequa às os requisitos de segurança, validando que seus dinheiro e dados pessoais estejam bem guardados.

    O Cbet Brasil está uma tornado uma alternativa popular dentre os, dado que oferece games na versão brasileiro. Essa melhora a experiência para quem gosta eliminar lidar com barreiras de comunicação. Ainda, essa plataforma garante que os vivenciem poker online e vários jogos de de maneira, facilitando a essa navegação cada vez menos atrativa.

    Antes de os potenciais está a respeito da confiabilidade da plataforma Cbet Online, é sempre sempre necessário estudar experiências de outros e também verificar se a plataforma ter comentários positivas. Uma forte credibilidade dentro do área de jogos de azar digitais é um bom símbolo de que se revela profissional e atenta com o bem-estar de jogadores.

    Em resumo, esse ambiente Cbet Jogo pode ser considerado uma possibilidades para procura atividades também desafios mediante apostas. No é crucial importante executar uma revisão aprofundada antes de se de se registrar, assegurando que a plataforma esse ambiente atenda às de proteção e. Caso você deseja está atrás em direção a uma vivência segura, esse Cbet pode ser considerado uma opção confiável para explorar o cenário de jogos online de modo segura.

  2. duospin-Vaskisy

    Assuming you are scouting for a brand-new and thrilling gambling hub, the site provided at duospin-casino-2.vercel.app is rapidly accruing popularity within fans throughout the territory [url=https://duospin-casino-2.vercel.app]duo spin casino review[/url] . Users looking for a reliable duospin canada experience will realize that this page offers a varied array of top-notch rounds, extending from classic pokies to engaging interactive host experiences. While the fame of this company expands, numerous patrons are hunting for a detailed duo spin casino review to comprehend what causes this location excel in a crowded online landscape.

    Once you browse the duospin online casino, you will perceive a simplified layout designed for alike smartphone and computer participants. The emphasis is on delivering a fluid space where you can enjoy your top games minus excessive distractions. Those composing a duospin review regularly emphasize the fluidity of browsing and the fast loading times, that are crucial for a elite gambling venture. Whether you are a occasional user or somebody who prefers to wager a calculated duospin bet, the platform accommodates a vast variety of gambling methods and inclinations.

    For what reason is the casino duospin setup evolving into a favored option for countless? It comes down to the devotion to excellence and integrity. Upon perusing a duospin casino review, you will discover steady accolades for the range of software creators and the transparency of the gameplay. Using picking the duospin casino online experience, you gain access to a modern platform whereby values player protection and amusement.

    If you are now examining a duo spin casino review to determine the location to allocate your leisure time, recall that this portal merges creativity with accessibility. The duo spin label is consistently forging a name for quality in the Maple Leaf sector. If you are ready to explore everything which casino duo spin has to present, the current hub provides a simple path to high-stakes excitement. Enjoy the features of duospin casino instantly and witness why so plenty of players are switching over to this active betting destination.

  3. В статье рассматриваются различные стратегии борьбы с зависимостями, включая проверенные методы и реальные истории успеха. Читатель узнает, какие подходы наиболее эффективны и как начать путь к выздоровлению.
    Подробнее тут – [url=https://narkologiya.pro/alkogolizm/kakie-metody-kodirovaniya-ot-alkogolya-samye-effektivnye/]наркологический центр[/url]

  4. В реальности Воронежа на самочувствие влияет не только фармакология, но и логистика: трассы с плотным трафиком, яркое освещение подъездов, очереди в медорганизациях. «ВоронежМедЦентр» гасит эти раздражители организационно: «тихие окна» приёма без коридорного шума, согласованная парковка, немаркированные выезды, нейтральные формулировки в документах и «беззвучные» напоминания. Снижение сенсорной нагрузки — это не декоративная опция, а клинический фактор: спокойная первая ночь, ровный пульс к вечеру, предсказуемость режима воды и тёплой пищи малыми порциями.
    Углубиться в тему – [url=https://narkologicheskaya-klinika-voronezh15.ru/]наркологическая клиника клиника помощь воронеж[/url]

  5. В данной публикации мы поговорим о процессе восстановления от зависимости, о том, как вернуть себе нормальную жизнь. Мы обсудим преодоление трудностей, значимость поддержки и наличие программ реабилитации. Читатели смогут узнать о ключевых шагах к успешному восстановлению.
    Переходите по ссылке ниже – [url=https://peredozirovka.info/articles/kak-vesti-sebya-s-zavisimym-chelovekom/]анонимная наркологическая клиника[/url]

  6. Обзор посвящён процессу восстановления после зависимостей. Мы расскажем о различных этапах реабилитации, поддерживающих ресурсах и важности мотивации в достижении устойчивого выздоровления.
    Получить профессиональную консультацию – [url=https://rentalz.ru/pages/platnoe-lechenie-alkogolizma/]алкоголь лечение алкоголизма[/url]

  7. Εφόσον ψάχνετε μια μοναδική διασκέδαση στον χώρο του online gaming, το spinogambino αποτελεί έναν από τους πιο περιζήτητους κόμβους για τους παίκτες στην Ελλάδα [url=https://spino-gambino-casino.gr]spinogambino[/url] . Το spinogambino casino παρέχει μια τεράστια συλλογή από παιχνίδια που καλύπτουν κάθε επιθυμία, από γνωστούς κουλοχέρηδες με μεγάλα τζακπότ έως σύγχρονα live παιχνίδια με έμπειρους κρουπιέρηδες που γεννούν μοναδικές συγκινήσεις. Η πλατφόρμα έχει δημιουργηθεί για να εγγυάται προστασία και άνεση στη χρήση, μετατρέποντας το spino gambino μια ιδανική απόφαση είτε για αμύητους όσο και για έμπειρους παίκτες.

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

    Ένα εκ τα βασικά χαρακτηριστικά που καθιστούν το spinogambino ελλάδα πολύ δημοφιλές είναι η ταχύτητα στις πληρωμές και η εξυπηρετική υποστήριξη πελατών. Αν διαλέγετε το spino gambino καζινο, έχετε πρόσβαση σε μια κοινότητα που παρέχει σημασία στην προστασία των στοιχείων σας και στην νόμιμη ψυχαγωγία. Είτε αποτελείτε λάτρης των slots είτε διαλέγετε τη ενέργεια που προσφέρει το spinogambino betting, η σελίδα παρέχει όλα τα απαραίτητα μέσα για μια συνολική και απολαυστική εμπειρία. Η περιήγηση είναι φιλική και η ανάλυση των animations μεταφέρει την ατμόσφαιρα ενός επίγειου καζίνο άμεσα στην οθόνη του υπολογιστή ή του smartphone σας. Μην σπαταλήσετε την πιθανότητα να βρείτε τις δυνατότητες που παρέχει το spinogambino και να τεστάρετε την μοίρα σας σε ένα χώρο που διακρίνεται για την ποιότητα και την ποικιλία των παροχών του. [url=https://agbmarshall.com/2021/11/28/3-ways-to-level-up-your-photography/#comment-6858]Εξερευνήστε το Spinogambino Ελλάδα: Η απόλυτη εμπειρία για στοίχημα και διασκέδαση στην Ελλάδα![/url] [url=http://duopharm.sn/2026/07/11/inauguration-du-nouveau-siege-du-groupe-duopharm/]Εξερευνήστε το Spinogambino Ελλάδα: Η κορυφαία προορισμός για slots και δράση στην Ελλάδα![/url] a77327a

  8. myjackpot-Arteni

    Investiguer la sphere des loisirs en ligne ne s’est point avere si simple avec la plateforme myjackpot [url=https://myjackpot-4.vercel.app]jeux my jackpot[/url] . Si vous etes a la recherche d’un instant ludique prenante, le site myjackpot-4.vercel.app s’affirme comme une destination de predilection pour les adeptes de divertissement numerique. En explorant ce portail, vous plongez dans une collection fournie ou tout membre peut denicher son bonheur parmi une vaste selection de divertissements.

    Le casino my jackpot est pense pour proposer une ergonomie rapide et intuitive, permettant aux joueurs de circuler sans difficultes entre les nombreuses rubriques de titres disponibles. Que vous soyez un habitue ou un novice, les jeux my jackpot se trouvent adaptes pour garantir une fluidite optimale sur tous vos appareils. La finesse visuelle et la vitesse de chargement font de ce site une institution pour ceux qui cherchent a se divertir en toute serenite.

    Pour rejoindre votre compte prive, il suffit d’effectuer votre my jackpot login en quelques secondes. Une fois connecte, vous jouissez d’un moment sur-mesure au sein de ce casino myjackpot moderne. La fiabilite et la discretion sont l’enjeu majeur sur myjackpot, offrant ainsi aux membres un espace securise pour consommer leurs parties.

    Si vous vous interrogez pourquoi choisir cet espace, retenez que my jackpot fr a ete pense pour combler les desiratas des parieurs francophones en offrant une interface claire et un choix etendu. La diversite des options disponibles sur ce site permet a chacun de varier les plaisirs selon ses envies. En resume, si vous recherchez une destination moderne qui combine simplicite et variete de jeux, n hesitez pas a visiter ce que cette adresse a a vous donner. La facilite d’acces, alliee a une architecture claire, positionne ce portail un point de passage pour quiconque souhaite s’amuser tranquillement sur le web. Adherez a la foule et devoilez des ce jour tout le la puissance de divertissement qui vous guette sur cette interface dediee au plaisir du jeu en ligne.

  9. spinmamalogincasino-Skeli

    Grasping the legal structure of an online gambling platform is crucial for every user, and the spin mama terms and conditions page functions as the foundation for a secure and clear wagering atmosphere [url=https://spinmamalogincasino.com/terms-and-conditions]spinmama[/url] . When you visit the official website, you gain access to a thorough document that outlines the policies governing your profile, betting activities, and financial transactions. Reading these conditions is the most effective way to safeguard your rights while enjoying the diverse range of games offered at spinmama.

    The terms and conditions page details critical aspects such as registration criteria, age confirmation, and bonus application rules. For instance, players must confirm they satisfy the legal gambling age in their region before opening an account. Additionally, the platform outlines precise guidelines concerning promotional offers. By familiarizing yourself with these stipulations, you can steer clear of common pitfalls, such as failing to meet wagering requirements before attempting a withdrawal. Grasping these terms ensures that your experience at spin mama stays fun and stress-free.

    Furthermore, the document explains the site’s dedication to responsible gaming. It offers information on configuring deposit limits, self-exclusion periods, and methods for control your betting habits effectively. Security is another pillar of the spin mama experience; the terms clarify how the operator secures your private information and guarantees fair play through certified random number generators. By consistently checking the policy, you remain informed about any changes to the platform policies, which helps uphold a trustworthy relationship between the operator and the player.

    Regardless of whether you are a first-time user or an seasoned player, taking the time to examine the full policy is a mark of a responsible user. It enables you to navigate the site’s tools with certainty, knowing precisely what is expected of you and what you can anticipate from the service. Visit the main spin mama website now to examine the entirety of the terms and conditions, ensuring your gaming journey remains secure, clear, and fun from start to end.

댓글 달기

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