Skip to content

Questions about the project structure #26

@fdcastel

Description

@fdcastel

This project is an excellent resource for new users. However, there are several things that I think should be better explained or refactored.

I tried to browse the topics on http://websharper.com/docs hoping to get some answers, but to no avail. What about to make an article about the build process? ;)

Some questions:

  1. The "src/" folder contains "bin/" and "obj/" subfolders (!?).

This certainly is not right. Maybe it could be called "app/" or something else? Or, better yet, to move the generated assets to another folder outside "src/" ? ("build/", probably?)

  1. The build process generates output in TWO different folders ("src/Content/" and "build/"). Why? Also, why the "build/" folder have no binaries and only client-side assets (js, css, html)?

I understand that "src/Content/" should be kept updated during debug time. However, shouldn't the build/ folder have everything needed to run the application, except the sources (e.g. for a "xcopy deploy")?

  1. The application uses "style.css" and some images from "files/" folder. The "style.css" is copied to "build/" folder. But the "files/" folder aren't? All the static assets shouldn't be handled the same way?

Also, there is some kind of "registration" procedure for asset files? I mean: some way to tell the build process that these files are needed to deploy?

BTW: WebSharper.UI.Next.Samples.css is always empty (0 bytes). What is it for? How can I add some content to it? At first glance I expected it to have the content of "style.css" and every other .css put in "src/" folder (like several other web frameworks do today).

  1. What is "WebSharper.UI.Next.Samples.head.html" for? I understand the need for separating ".js" and ".head.js". But, why the ".html"?

  2. Any reason to keep the old nuget package restore instead the new one? https://docs.nuget.org/consume/package-restore/migrating-to-automatic-package-restore

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions