├── docs └── .keep ├── src ├── assets │ ├── fonts │ │ └── .keep │ ├── images │ │ ├── .keep │ │ └── elm.png │ ├── favicon.ico │ └── index.html ├── javascripts │ └── application.js ├── stylesheets │ ├── global │ │ ├── fonts.scss │ │ ├── mixins.scss │ │ ├── overloads.scss │ │ ├── settings.scss │ │ └── forms.scss │ ├── application.scss │ └── modules │ │ └── e-application-layout.scss └── elm │ ├── Application.elm │ └── Application │ └── Layout.elm ├── tests ├── .gitignore ├── elm-package.json └── Tests.elm ├── .gitignore ├── .editorconfig ├── elm-uninstall.sh ├── brunch-config.js ├── elm-package.json ├── package.json ├── LICENSE ├── .travis.yml └── README.md /docs/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/fonts/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/images/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/.gitignore: -------------------------------------------------------------------------------- 1 | /elm-stuff/ 2 | -------------------------------------------------------------------------------- /src/javascripts/application.js: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | public/ 3 | **/elm-stuff/ 4 | .DS_Store 5 | npm-debug.log 6 | 7 | -------------------------------------------------------------------------------- /src/assets/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/khusnetdinov/elmkit/HEAD/src/assets/favicon.ico -------------------------------------------------------------------------------- /src/assets/images/elm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/khusnetdinov/elmkit/HEAD/src/assets/images/elm.png -------------------------------------------------------------------------------- /src/stylesheets/global/fonts.scss: -------------------------------------------------------------------------------- 1 | @import "settings"; 2 | 3 | // Place here all relate to Fonts 4 | 5 | -------------------------------------------------------------------------------- /src/stylesheets/global/mixins.scss: -------------------------------------------------------------------------------- 1 | @import "settings"; 2 | 3 | // Here place all you custom global mixins 4 | 5 | -------------------------------------------------------------------------------- /src/stylesheets/global/overloads.scss: -------------------------------------------------------------------------------- 1 | @import "settings"; 2 | 3 | // Place here all relate to overloading 3rd party styles 4 | 5 | -------------------------------------------------------------------------------- /src/stylesheets/global/settings.scss: -------------------------------------------------------------------------------- 1 | // Here is best place for importing 3rd party libraries 2 | // And defining global variables 3 | -------------------------------------------------------------------------------- /src/stylesheets/global/forms.scss: -------------------------------------------------------------------------------- 1 | @import "settings"; 2 | 3 | // Place here all relate to globall styles for all forms components 4 | 5 | -------------------------------------------------------------------------------- /src/elm/Application.elm: -------------------------------------------------------------------------------- 1 | module Application exposing (main) 2 | 3 | import Html exposing (text) 4 | 5 | import Application.Layout as Layout exposing (view) 6 | 7 | main = 8 | Layout.view 9 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = space 5 | indent_size = 2 6 | end_of_line = lf 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | insert_final_newline = true 10 | 11 | [{package,elm-package}.json] 12 | indent_style = space 13 | indent_size = 2 14 | -------------------------------------------------------------------------------- /src/stylesheets/application.scss: -------------------------------------------------------------------------------- 1 | @import "global/forms"; 2 | @import "global/fonts"; 3 | @import "global/mixins"; 4 | @import "global/overloads"; 5 | 6 | .body { 7 | display: block; 8 | position: relative; 9 | 10 | margin: 0; 11 | padding: 0; 12 | 13 | font: 16px / 16px; 14 | } 15 | 16 | @import "modules/e-application-layout"; 17 | -------------------------------------------------------------------------------- /src/stylesheets/modules/e-application-layout.scss: -------------------------------------------------------------------------------- 1 | @import "../global/settings"; 2 | 3 | .e-application-layout { 4 | display: block; 5 | position: relative; 6 | width: 450px; 7 | margin: 150px auto; 8 | padding: 0; 9 | text-align: center; 10 | color: #505050; 11 | 12 | > .elm-logo { 13 | width: 175px; 14 | height: 175px; 15 | } 16 | 17 | > .title { 18 | margin-top: 20px; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /src/elm/Application/Layout.elm: -------------------------------------------------------------------------------- 1 | module Application.Layout exposing (view) 2 | 3 | import Html exposing (div, img, h2, p, ul, li, a, text) 4 | import Html.Attributes exposing (class, src, alt, href) 5 | 6 | view = 7 | div [ class "e-application-layout" ] 8 | [ img [ class "elm-logo", src "/images/elm.png", alt "Elm boilerplate kit" ][] 9 | , h2 [ class "title" ] [ text "Hello world from Elm boilerplate kit!" ] 10 | ] 11 | 12 | -------------------------------------------------------------------------------- /elm-uninstall.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e 4 | 5 | echo "Warning: You are about to remove all Elm executables!" 6 | 7 | installdir=/usr/local/bin 8 | 9 | for bin in elm elm-compiler elm-get elm-reactor elm-repl elm-doc elm-server elm-package elm-make 10 | do 11 | if [ -f $installdir/$bin ]; then 12 | sudo rm -f $installdir/$bin 13 | fi 14 | if [ -f $installdir/$bin-unwrapped ]; then 15 | sudo rm -f $installdir/$bin-unwrapped 16 | fi 17 | 18 | done 19 | 20 | sharedir=/usr/local/share/elm 21 | sudo rm -rf $sharedir 22 | -------------------------------------------------------------------------------- /brunch-config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | config: { 3 | server: { 4 | port: 3000 5 | }, 6 | paths: { 7 | watched: ["src", "spec"] 8 | }, 9 | files: { 10 | javascripts: { joinTo: "javascripts/application.js" }, 11 | stylesheets: { joinTo: "stylesheets/application.css" } 12 | }, 13 | plugins: { 14 | sass: { 15 | mode: 'native' 16 | }, 17 | elmBrunch: { 18 | mainModules: ['src/elm/Application.elm'], 19 | outputFolder: "public/javascripts/", 20 | outputFile: "elm.js", 21 | makeParameters: ['--debug'] 22 | } 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /elm-package.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.1.0", 3 | "summary": "Elm starter kit", 4 | "repository": "https://github.com/khusnetdinov/elmkit.git", 5 | "license": "MIT", 6 | "source-directories": [ 7 | ".", 8 | "src/elm/", 9 | "spec/" 10 | ], 11 | "exposed-modules": [], 12 | "dependencies": { 13 | "elm-community/elm-test": "4.2.0 <= v < 5.0.0", 14 | "elm-community/json-extra": "2.0.0 <= v < 3.0.0", 15 | "elm-lang/core": "5.0.0 <= v < 6.0.0", 16 | "elm-lang/html": "2.0.0 <= v < 3.0.0", 17 | "mgold/elm-random-pcg": "4.0.2 <= v < 5.0.0" 18 | }, 19 | "elm-version": "0.18.0 <= v < 0.19.0" 20 | } 21 | -------------------------------------------------------------------------------- /tests/elm-package.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.0.1", 3 | "summary": "Elm starter kit", 4 | "repository": "https://github.com/khusnetdinov/elmkit.git", 5 | "license": "MIT", 6 | "source-directories": [ 7 | ".", 8 | "src/elm/", 9 | "spec/" 10 | ], 11 | "exposed-modules": [], 12 | "dependencies": { 13 | "elm-community/elm-test": "4.2.0 <= v < 5.0.0", 14 | "elm-community/json-extra": "2.0.0 <= v < 3.0.0", 15 | "elm-lang/core": "5.0.0 <= v < 6.0.0", 16 | "elm-lang/html": "2.0.0 <= v < 3.0.0", 17 | "mgold/elm-random-pcg": "4.0.2 <= v < 5.0.0" 18 | }, 19 | "elm-version": "0.18.0 <= v < 0.19.0" 20 | } 21 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "elmkit", 3 | "version": "0.1.0", 4 | "description": "Elm starter kit", 5 | "keywords": [], 6 | "repository": { 7 | "type": "git", 8 | "url": "https://github.com/khusnetdinov/elmkit" 9 | }, 10 | "author": "Marat Khusnetdinov", 11 | "license": "MIT", 12 | "main": "brunch-config.js", 13 | "devDependencies": { 14 | "auto-reload-brunch": "^2.7.1", 15 | "brunch": "^4.0.2", 16 | "elm-brunch": "^0.7.0", 17 | "elm-test": "^0.19.1", 18 | "hmr-brunch": "^0.1.1", 19 | "sass-brunch": "^3.0.0" 20 | }, 21 | "scripts": { 22 | "development": "brunch watch --server", 23 | "build": "brunch build --production", 24 | "test": "rm tests/elm-package.json && cp elm-package.json tests && elm-test" 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2016 Marat Khusnetdinov 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - "6" 4 | - "node" 5 | 6 | env: 7 | - ELM_VERSION=0.19.1 8 | 9 | before_install: 10 | - if [ ${TRAVIS_OS_NAME} == "osx" ]; 11 | then brew update; brew install nvm; mkdir ~/.nvm; export NVM_DIR=~/.nvm; source $(brew --prefix nvm)/nvm.sh; 12 | fi 13 | - echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config 14 | - | # epic build time improvement - see https://github.com/elm-lang/elm-compiler/issues/1473#issuecomment-245704142 15 | if [ ! -d sysconfcpus/bin ]; 16 | then 17 | git clone https://github.com/obmarg/libsysconfcpus.git; 18 | cd libsysconfcpus; 19 | ./configure --prefix=$TRAVIS_BUILD_DIR/sysconfcpus; 20 | make && make install; 21 | cd ..; 22 | fi 23 | 24 | install: 25 | - node --version 26 | - npm --version 27 | - npm install -g elm-use elm-test 28 | - elm-use $ELM_VERSION 29 | - mv $(npm config get prefix)/bin/elm-make $(npm config get prefix)/bin/elm-make-old 30 | - printf '%s\n\n' '#!/bin/bash' 'echo "Running elm-make with sysconfcpus -n 2"' '$TRAVIS_BUILD_DIR/sysconfcpus/bin/sysconfcpus -n 2 elm-make-old "$@"' > $(npm config get prefix)/bin/elm-make 31 | - chmod +x $(npm config get prefix)/bin/elm-make 32 | - travis_retry elm-package install --yes 33 | - cd tests 34 | - travis_retry elm-package install --yes 35 | - cd .. 36 | 37 | script: 38 | - npm test 39 | -------------------------------------------------------------------------------- /src/assets/index.html: -------------------------------------------------------------------------------- 1 | 2 |
3 | 4 | 5 | 6 | 7 |