Questions tagged [static-site]

Static sites are websites that have no dynamic components, e.g. databases or server-side scripting languages. A number of static site generators exist in a variety of languages, such as Jekyll, Wintersmith, and Pelican.

523 questions
14
votes
4 answers

Nuxt.js static site and 404 page

I have currently created a pages/404.vue file, then, in my server settings, I redirect any non existent url to /404.html (the generated page). Apart me having to declare the file extension (it gives me redirect error if I redirect to /404), it seems…
Saro
  • 529
  • 1
  • 7
  • 19
14
votes
3 answers

Using a S3 Static Site with an Application Load Balancer

I have an ALB that currently routes traffic to multiple urls. I'd like to be able to route traffic to a Static S3 site in the event that we need to perform maintenance. We would then display a static "Maintenance" page instead of our login page. I…
13
votes
3 answers

How to link your own articles on a Pelican blog?

I tried to link with the html file name, but it works because they are on the same folder. [Title](./this-is-the-file.html) But it is possible that another article would appear on another folder because of the ARTICLE_URL pattern. Examples: [Title…
jordiburgos
  • 5,964
  • 4
  • 46
  • 80
12
votes
2 answers

Netlify: How do you deploy sites that are nested in a folder?

I have a repo that has the backend and frontend (create-react-app) in two separate folders. For the build command, I have something like cd frontend && npm run build and for the publish directory, I have something like frontend/build, but this is…
sdfsdf
  • 5,052
  • 9
  • 42
  • 75
12
votes
2 answers

Access Denied for index.html Amazon S3 static website

I've set up an example static website on Amazon S3 and I added a custom folder to it with file inside: custom-folder/index.html, but I'm getting Access Denied error when trying to access url /custom-folder. The index document is configured to be…
Oleksandr.Bezhan
  • 2,028
  • 3
  • 22
  • 31
12
votes
2 answers

Django: AttributeError: 'NoneType' object has no attribute 'split'

I'm trying to build a static site generator using Django (because its resourceful that way), and right now my problems are dealing with the Django command that is supposed to build my static site content into a directory. Apparently my 'NoneType'…
JellisHeRo
  • 537
  • 1
  • 7
  • 17
12
votes
3 answers

How to include simple JavaScript within Hugo

Given the following code: $('img').mouseenter(function(){ //... }).mouseleave(function(){ //... }); I'd like it to be included in my articles. I'd like to avoid editing the theme if possible so to avoid forking etc.
Mitchell Currie
  • 2,769
  • 3
  • 20
  • 26
11
votes
1 answer

How do I choose a category page to be the home page for a Pelican site?

I would like the visitors to my site to land on a category page, not on the default index.html. I want them to see the articles in the News categories before anything else. Maybe is there a way to tell Pelican to output category/news to index.html?…
CamilB
  • 1,377
  • 1
  • 12
  • 27
10
votes
3 answers

How can I use getInitialProps only during the NextJS site build?

When using NextJS to build a static site, I would like the getInitialProps method to fire only during the build step and not on the client. In the build step, NextJS runs the getInitialProps method before each component's rendered HTML is used to…
brettinternet
  • 546
  • 7
  • 21
10
votes
2 answers

Rewrite URL for static website hosted in Azure Storage

I have deployed Angular 7 app to Azure Storage Static Website. Angular app makes calls to .NET Core API which is deployed to Azure App Service. Is it possible to configure URL rewrite (reverse proxy) to route Angular app requests to .NET Core API…
9
votes
4 answers

How to get previous url in react gatsby

I am pretty much familiar with the React.js but new to Gatsby. I want to detect the previous page URL in Gatsby?
Profer
  • 553
  • 8
  • 40
  • 81
9
votes
2 answers

What is a static site generator?

After ditching Wordpress, I've been experimenting with Jekyll to create a blog. I chose it (over Ghost) to help learn the basics of web development while I blogged. Also, the free hosting on GitHub Pages is neat and free. What exactly is a static…
Nitin Savant
  • 931
  • 1
  • 8
  • 19
9
votes
2 answers

Jekyll multiple post types

I'm currently building my new personal website and I'm trying out Jekyll, now I was wondering what the best way is to get multiple post types. I basically want to have 2 categories: blog and work I was looking up some ways and one way was to just…
woutr_be
  • 9,532
  • 24
  • 79
  • 129
9
votes
5 answers

How do you turn a dynamic site into a static site that can be demo'd from a CD?

I need to find a way to crawl one of our company's web applications and create a static site from it that can be burned to a cd and used by traveling sales people to demo the web site. The back end data store is spread across many, many systems so…
John Miller
  • 999
  • 1
  • 9
  • 15
8
votes
1 answer

GitLab pages: can a static site be generated from a project wiki?

So I know that GitLab pages can be employed to generate a static website from a project's repository. What I'd like to do however, is generate a static site from a project's wiki, which is a separate repository. I also know that I could hook a…
wu-lee
  • 749
  • 4
  • 17
1
2
3
34 35