Skip to content

Commit

Permalink
ktl-1115 feat: add next.js front page
Browse files Browse the repository at this point in the history
  • Loading branch information
krutilov committed Jul 3, 2023
1 parent 32fcc85 commit 1746ab8
Show file tree
Hide file tree
Showing 4 changed files with 264 additions and 257 deletions.
5 changes: 5 additions & 0 deletions kotlin-website.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,11 @@ def index_page():
features=features
)


@app.route('/main')
def next_index_page():
return send_file(path.join(root_folder, 'out', 'main/index.html'))

def process_page(page_path):
# get_nav() has side effect to copy and patch files from the `external` folder
# under site folder. We need it for dev mode to make sure file is up-to-date
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
"use-match-media-hook": "1.0.1",
"validator": "13.7.0",
"webpack": "5.76.0",
"webpack-cli": "4.7.2",
"webpack-cli": "5.1.4",
"whatwg-fetch": "2.0.2"
},
"devDependencies": {
Expand All @@ -91,7 +91,7 @@
"prettier": "2.6.2",
"start-server-and-test": "1.14.0",
"typescript": "4.6.3",
"webpack-dev-server": "4.3.1",
"webpack-dev-server": "^4.15.1",
"yaml-loader": "0.7.0"
},
"scripts": {
Expand Down
11 changes: 11 additions & 0 deletions pages/main/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import React from 'react';

function Index() {
return (
<section>
<h2>Next.js front page</h2>
</section>
);
}

export default Index;
Loading

0 comments on commit 1746ab8

Please sign in to comment.