Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

typical modify #27

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 0 additions & 31 deletions rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,10 @@ import resolve from "@rollup/plugin-node-resolve";
import commonjs from "@rollup/plugin-commonjs";
import livereload from "rollup-plugin-livereload";
import { terser } from "rollup-plugin-terser";
// library that helps you import in svelte with
// absolute paths, instead of
// import Component from "../../../../components/Component.svelte";
// we will be able to say
// import Component from "components/Component.svelte";
import alias from "@rollup/plugin-alias";
import fs from "fs";

const production = !process.env.ROLLUP_WATCH;

// configure aliases for absolute imports
const aliases = alias({
resolve: [".svelte", ".js"], //optional, by default this will just look for .js files or folders
entries: [
Expand Down Expand Up @@ -154,43 +147,19 @@ export default {
},
plugins: [
svelte({
// enable run-time checks when not in production
dev: !production,
// we'll extract any component CSS out into
// a separate file - better for performance
css: (css) => {
css.write("bundle.css");
},
}),

// If you have external dependencies installed from
// npm, you'll most likely need these plugins. In
// some cases you'll need additional configuration -
// consult the documentation for details:
// https://github.com/rollup/plugins/tree/master/packages/commonjs
resolve({
browser: true,
dedupe: ["svelte"],
}),
commonjs(),

// In dev mode, call `npm run start` once
// the bundle has been generated
!production && serve(),

// Watch the `public` directory and refresh the
// browser on changes when not in production
!production && livereload("public"),

// If we're building for production (npm run build
// instead of npm run dev), minify
production && terser(),

// for absolut imports
// i.e., instead of
// import Component from "../../../../components/Component.svelte";
// we will be able to say
// import Component from "components/Component.svelte";
aliases,
],
watch: {
Expand Down
3 changes: 0 additions & 3 deletions src/views/Index.svelte
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
<script>
import { Link } from "svelte-routing";

// core components
import IndexNavbar from "components/Navbars/IndexNavbar.svelte";
import Footer from "components/Footers/Footer.svelte";

const patternVue = "/assets/img/pattern_svelte.png";
const componentBtn = "/assets/img/component-btn.png";
const componentProfileCard = "/assets/img/component-profile-card.png";
Expand Down
1 change: 0 additions & 1 deletion src/views/admin/Maps.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<script>
// core components
import MapExample from "components/Maps/MapExample.svelte";
export let location;
</script>
Expand Down