Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

svelte-preprocess

Package Overview
Dependencies
Maintainers
1
Versions
175
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

svelte-preprocess - npm Package Compare versions

Comparing version 2.1.3 to 2.1.4

2

package.json
{
"name": "svelte-preprocess",
"version": "2.1.3",
"version": "2.1.4",
"license": "MIT",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -24,5 +24,5 @@ # Svelte Preprocess

const svelte = require('svelte')
const getSveltePreprocessor = require('svelte-preprocess')
const preprocess = require('svelte-preprocess')
svelte.preprocess(input, getSveltePreprocessor()).then(...)
svelte.preprocess(input, preprocess({ /* options */ })).then(...)
```

@@ -34,3 +34,3 @@

const svelte = require('svelte')
const getSveltePreprocessor = require('svelte-preprocess')
const preprocess = require('svelte-preprocess')
const options = {

@@ -93,5 +93,28 @@ /** Transform the whole markup before preprocessing */

svelte.preprocess(input, getSveltePreprocessor(options)).then(...)
svelte.preprocess(input, preprocess(options)).then(...)
```
### With `svelte-loader`
```js
...
module: {
rules: [
...
{
test: /\.(html|svelte)$/,
exclude: /node_modules/,
use: {
loader: 'svelte-loader',
options: {
preprocess: require('svelte-preprocess')({ /* options */ })
},
},
},
...
]
}
...
```
## Features

@@ -98,0 +121,0 @@

@@ -100,3 +100,3 @@ const stripIndent = require('strip-indent')

return runTransformer('postcss', transformers.postcss, {
content: code,
content: stripIndent(code),
filename: assetInfo.filename,

@@ -103,0 +103,0 @@ map,

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc