Giter VIP home page Giter VIP logo

Comments (23)

doriansmiley avatar doriansmiley commented on August 30, 2024

I think you should create a feature branch and test it there. We do have some unit tests you can run (just execute npm test) in addition to performing usability testing under the example directory. If everything passes then for sure issue a pull request. Would really like to get updated to the latest x-tag ASAP.

from lotusjs.

doriansmiley avatar doriansmiley commented on August 30, 2024

@KipOmaha let me know if you want help on this

from lotusjs.

 avatar commented on August 30, 2024

https://github.com/x-tag/core/tree/v2 <= link to v2 branch in the repo

from lotusjs.

 avatar commented on August 30, 2024

When would it be best to start collaborating on this?

from lotusjs.

doriansmiley avatar doriansmiley commented on August 30, 2024

@KipOmaha I'd like to start today. If you've already created a feature branch let me know and I'll work in that branch. If not I'll create one and post the branch here.

from lotusjs.

 avatar commented on August 30, 2024

I haven't created a branch yet @doriansmiley

from lotusjs.

doriansmiley avatar doriansmiley commented on August 30, 2024

@KipOmaha not yet, won't get back on this until around 5PM PST. If you want to create a branch before then just post it here.

from lotusjs.

 avatar commented on August 30, 2024

ok

from lotusjs.

 avatar commented on August 30, 2024

I am going to put lotusJS on my dashboard. The dashboard isn't done yet, but I think it will do for some testing.

from lotusjs.

 avatar commented on August 30, 2024

sorry didn't mean to close this issue

from lotusjs.

doriansmiley avatar doriansmiley commented on August 30, 2024

@KipOmaha sounds good. Not sure how your dashboard is created but if it is pure Javascript you can see an example of a component that is build in pure Javascript here: https://github.com/doriansmiley/lotusJS-MWV/blob/master/example/sampleApp/js/view/PageNumberDisplay.js . It is totally fine to use LotusJS to create custom components outside of TypeScript. I plan to include some more Javascript examples so maybe this is a good start.

from lotusjs.

 avatar commented on August 30, 2024

kool, it uses javascript. I've been looking at the typescript, in the examples and how it works with the Javascript. It's interesting how it's mapped out, did you get a chance to look at v2?

from lotusjs.

 avatar commented on August 30, 2024

Haven't made a push to the repo, I want to finish the x-tabbox component, it was going to use jasmine so that it could be useful to test custom elements. https://github.com/KipOmaha/x-tag-setup

from lotusjs.

doriansmiley avatar doriansmiley commented on August 30, 2024

@KipOmaha I start looking at V2 last night. Going to take a deeper look tonight and attempt to run tests against the build. One thing I am having a hard time tracking down are release notes, or a summary of the issues that were added to this release.

from lotusjs.

 avatar commented on August 30, 2024

There are jasmine tests that you can take a look at.

from lotusjs.

 avatar commented on August 30, 2024

There are docs in the => https://github.com/KipOmaha/x-tag-setup/tree/master/pkgs/docs directory

from lotusjs.

 avatar commented on August 30, 2024

I'm pushing lotusJS to the build

from lotusjs.

 avatar commented on August 30, 2024

The last commit was for an issue involving a recursion error occurring when you used an auto rendering feature of the library. I also noticed that camel casing didn't work for me, but I put a shim into the build to fix it real quick.

Also the commit that fixed the recursion error causes the ability to re-render the element to cause an error.

from lotusjs.

doriansmiley avatar doriansmiley commented on August 30, 2024

@KipOmaha I started testing against x-tag v2 and the first issue I found was with the register function. It looks like a breaking change was introduced in v2 with that method. The old method was implemented as follows:

register: function (name, options) {
//full code ommited
}

The new method is implemented as follows:

,
    register (name, klass) {
      customElements.define(name, klass);
    }

Where customElements is an instance of CustomElementRegistry or the pollyfill created by x-tag. The define method's signature is defined as follows: customElements.define(name, constructor, options);. So in the new register the second parameter is a constructor and not an options object that exposes lifecycle and prototype properties.

We'll have to refactor lotus's component map to adjust for this. Ideally x-tag would not introduce a breaking change like this. I think it would have been better to moved calls to CustomElementRegistry under the current register method allowing existing code to still pass options as the second param in the call to register.

Another issue that I having is where the source for x-tag-polyfilled.js is. Any ideas?

Doe x-tag V2 still require x-tag/lib/webcomponents.js or are those files included now in the plugins directory?

from lotusjs.

 avatar commented on August 30, 2024

Sorry I didn't see this in the issues. It's using custom-elements.js and doesn't use the shadow dom.

from lotusjs.

 avatar commented on August 30, 2024

I was thinking of adding the shadow dom files to see about compat. would this be needed?

from lotusjs.

 avatar commented on August 30, 2024

@doriansmiley,

I'm going to try out,

// ***** XTAG.BUILDER()
xtag.builder = function build(opts) {
	let _bd = null,
             _bds = xtag.builds,
             klass = null;
	if(!opts) { return createClass(); };

	if( !_bds[opts.name] ) {
		klass = _bds[opts.name] = opts.update;
		klass = _bds[opts.name].update();
	}
	else {
		klass = _bds[opts.name].update();
	};
	return klass;
}
var myCustomBuild = xtag.builder( {
  update: function(){
    // Gather resources like webcomponents or shadowdom
    // Your Custom definition for xtag v2 [Bring in the v1 API that is needed]
  }
} )

Anybody like this idea for custom-element packages. The idea is to create the necessary xtag's object for that particular web page.

Should I test it on v1 so that we can build xtag v1 into v2 instead of vice versa?

from lotusjs.

 avatar commented on August 30, 2024

I would have to change a couple lines to make it work with v1 though

from lotusjs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.