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

@riotjs/dom-bindings

Package Overview
Dependencies
Maintainers
1
Versions
90
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@riotjs/dom-bindings - npm Package Compare versions

Comparing version 9.0.4 to 9.1.0

12

dist/dom-bindings.js

@@ -831,5 +831,10 @@ import { insertBefore, removeChild, replaceChild, cleanNode, moveChildren, clearChildren } from '@riotjs/util/dom';

// override the template property if the slot needs to be replaced
this.template =
templateData &&
create(templateData.html, templateData.bindings).createDOM(parentNode);
(templateData &&
create(templateData.html, templateData.bindings).createDOM(
parentNode,
)) ||
// otherwise use the optional template fallback if provided by the compiler see also https://github.com/riot/riot/issues/3014
this.template;

@@ -893,6 +898,7 @@ if (this.template) {

*/
function createSlot(node, { name, attributes }) {
function createSlot(node, { name, attributes, template }) {
return {
...SlotBinding,
attributes,
template,
node,

@@ -899,0 +905,0 @@ name,

@@ -92,5 +92,3 @@ // Expressions

export interface SlotBindingData<Scope = any> extends BaseBindingData<Scope> {
id: string
html: string
bindings: BindingData<Scope>[]
template?: TemplateChunk<Scope>
}

@@ -101,3 +99,7 @@

attributes: AttributeExpressionData<Scope>[]
slots: SlotBindingData<Scope>[]
slots: {
id: string
html: string
bindings: BindingData<Scope>[]
}[]
}

@@ -176,3 +178,5 @@

export const bindingTypes: BindingType
export const expressionTypes: ExpressionType
export const bindingTypes: { [key in keyof typeof BindingType]: BindingType }
export const expressionTypes: {
[key in keyof typeof ExpressionType]: ExpressionType
}
{
"name": "@riotjs/dom-bindings",
"version": "9.0.4",
"version": "9.1.0",
"description": "Riot.js DOM bindings",

@@ -22,3 +22,3 @@ "main": "dist/dom-bindings.cjs",

"postest": "npm run cov-html",
"bench": "node benchmarks/index.cjs",
"bench": "node --expose-gc benchmarks/index.cjs",
"test": "npm run lint && c8 mocha -r test/index.js 'test/**/*.spec.js' && npm run test-typing",

@@ -56,19 +56,19 @@ "test-typing": "tsc -p test",

"benchmark": "^2.1.4",
"c8": "^9.1.0",
"c8": "^10.1.2",
"chai": "^4.4.1",
"coveralls": "^3.1.1",
"eslint": "^8.56.0",
"eslint": "^8.57.0",
"eslint-config-riot": "^4.1.2",
"jsdom": "^24.0.0",
"jsdom": "^24.1.1",
"jsdom-global": "3.0.2",
"mocha": "^10.3.0",
"prettier": "^3.2.5",
"rollup": "^4.12.0",
"sinon": "^17.0.1",
"mocha": "^10.7.3",
"prettier": "^3.3.3",
"rollup": "^4.20.0",
"sinon": "^18.0.0",
"sinon-chai": "^3.7.0",
"typescript": "^5.3.3"
"typescript": "^5.5.4"
},
"dependencies": {
"@riotjs/util": "^2.2.4"
"@riotjs/util": "^2.4.0"
}
}

@@ -44,5 +44,10 @@ import { cleanNode, insertBefore, removeChild } from '@riotjs/util/dom'

// override the template property if the slot needs to be replaced
this.template =
templateData &&
template(templateData.html, templateData.bindings).createDOM(parentNode)
(templateData &&
template(templateData.html, templateData.bindings).createDOM(
parentNode,
)) ||
// otherwise use the optional template fallback if provided by the compiler see also https://github.com/riot/riot/issues/3014
this.template

@@ -106,6 +111,7 @@ if (this.template) {

*/
export default function createSlot(node, { name, attributes }) {
export default function createSlot(node, { name, attributes, template }) {
return {
...SlotBinding,
attributes,
template,
node,

@@ -112,0 +118,0 @@ name,

Sorry, the diff of this file is not supported yet

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