문제

I just read Dart's article on Assets and Transformers and want to make sure I am understanding the correct way of structuring your asset directory.

Say my project name is MyApp, and it should produce - after cross-compiling - a JavaScript file called myapp.dart.js. Here is how I have the asset directory set up:

MyProject/
    asset/
        bootstrap/
            css/
                ...
            fonts/
                ...
            js/
                ...
        myapp/
            ... myapp's CSS and images
        ...other package's assets
    web/
        ...

Am I doing this right? Or should I be placing my assets some place else, or in a different convention?

도움이 되었습니까?

해결책

Yes it's fine this way.

The asset directory is currently only supported by pub serve and pub build but not by the web server integrated into the Darteditor.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top